Files
peko-ios/YuMi/Modules/YMMine/View/Setting/XPMineAboutUsViewController.m
eggmanQQQ 2469e186b4 项目优化:
1. 版本号更新
2. Archive 使用 Debug 配置,蒲公英测试包可以切换环境
3. 移除不使用的第三方库“Weex”和对应文件
2024-06-12 10:45:15 +08:00

89 lines
2.3 KiB
Objective-C

//
// YMMineAboutUsViewController.m
// YUMI
//
// Created by YUMI on 2021/9/17.
//
#import "XPMineAboutUsViewController.h"
///Third
#import <Masonry/Masonry.h>
///Tool
#import "DJDKMIMOMColor.h"
#import "YYUtility.h"
#import "YUMIMacroUitls.h"
@interface XPMineAboutUsViewController ()
@property (nonatomic, strong) UIImageView *iconImageView;//图标
@property (strong, nonatomic) UILabel *versionLabel;//版本
@property (strong , nonatomic) UILabel *nameLabel;
@end
@implementation XPMineAboutUsViewController
- (void)viewDidLoad {
[super viewDidLoad];
self.title = [NSString stringWithFormat:@"%@%@",YMLocalizedString(@"XPMineSettingPresent19"),AppName];
[self initSubViews];
[self makeConstriants];
}
- (void)initSubViews {
[self.view addSubview:self.versionLabel];
[self.view addSubview:self.iconImageView];
[self.view addSubview:self.nameLabel];
}
- (void)makeConstriants {
[self.iconImageView mas_makeConstraints:^(MASConstraintMaker *make) {
make.centerX.mas_equalTo(self.view);
make.width.height.mas_equalTo(80);
make.top.mas_equalTo(kNavigationHeight+60);
}];
[self.nameLabel mas_makeConstraints:^(MASConstraintMaker *make) {
make.centerX.mas_equalTo(self.view);
make.top.mas_equalTo(self.iconImageView.mas_bottom).offset(5);
}];
[self.versionLabel mas_makeConstraints:^(MASConstraintMaker *make) {
make.top.mas_equalTo(self.nameLabel.mas_bottom).offset(5);
make.centerX.mas_equalTo(self.view);
}];
}
#pragma mark - Getter && Setter
- (UIImageView *)iconImageView {
if (!_iconImageView) {
_iconImageView = [[UIImageView alloc] init];
_iconImageView.image = [UIImage imageNamed:@"ming_setting_about_us"];
_iconImageView.layer.cornerRadius = 12;
_iconImageView.layer.masksToBounds = YES;
}
return _iconImageView;
}
- (UILabel *)versionLabel {
if (!_versionLabel) {
_versionLabel = [[UILabel alloc] init];
_versionLabel.font = [UIFont systemFontOfSize:12];
_versionLabel.textColor = [DJDKMIMOMColor mainTextColor];
_versionLabel.text = [NSString stringWithFormat:@"V%@",PI_App_Version];
}
return _versionLabel;
}
- (UILabel *)nameLabel {
if (!_nameLabel) {
_nameLabel = [[UILabel alloc] init];
_nameLabel.text = AppName;
_nameLabel.textColor = [DJDKMIMOMColor secondTextColor];
_nameLabel.font = [UIFont systemFontOfSize:17];
}
return _nameLabel;
}
@end