|
|
@@ -106,34 +106,35 @@
|
|
|
[_progressSelectView.layer addSublayer:_glayer];
|
|
|
|
|
|
|
|
|
- CGFloat butWidth = (SCREEN_W - 16*2 - 16*2)/3.0;
|
|
|
+ CGFloat butWidth = (SCREEN_W - 16*2 - 16*2)/2.0;
|
|
|
|
|
|
UIFont *curFont = [UIFont systemFontOfSize:12.0];
|
|
|
|
|
|
- NSArray *arLanguages = [[NSUserDefaults standardUserDefaults] objectForKey:@"AppleLanguages"];
|
|
|
- NSLog(@"arLanguages:%@",arLanguages);
|
|
|
- ///获取设备当前地区的代码和APP语言环境
|
|
|
- NSString *languageCode = [NSLocale preferredLanguages][0];
|
|
|
-
|
|
|
- //目前支持 中文(简体 繁体) 英文 日语
|
|
|
- if([languageCode rangeOfString:@"zh-Hans"].location != NSNotFound)
|
|
|
- {
|
|
|
- }
|
|
|
- else if([languageCode rangeOfString:@"zh-Hant"].location != NSNotFound)
|
|
|
- {
|
|
|
- }
|
|
|
- else{
|
|
|
- curFont = [UIFont systemFontOfSize:10.0];
|
|
|
- }
|
|
|
+// NSArray *arLanguages = [[NSUserDefaults standardUserDefaults] objectForKey:@"AppleLanguages"];
|
|
|
+// NSLog(@"arLanguages:%@",arLanguages);
|
|
|
+// ///获取设备当前地区的代码和APP语言环境
|
|
|
+// NSString *languageCode = [NSLocale preferredLanguages][0];
|
|
|
+//
|
|
|
+// //目前支持 中文(简体 繁体) 英文 日语
|
|
|
+// if([languageCode rangeOfString:@"zh-Hans"].location != NSNotFound)
|
|
|
+// {
|
|
|
+// }
|
|
|
+// else if([languageCode rangeOfString:@"zh-Hant"].location != NSNotFound)
|
|
|
+// {
|
|
|
+// }
|
|
|
+// else{
|
|
|
+// curFont = [UIFont systemFontOfSize:10.0];
|
|
|
+// }
|
|
|
|
|
|
_totalLabel = [[UILabel alloc] init];
|
|
|
_totalLabel.font = curFont;
|
|
|
+ _totalLabel.textAlignment = NSTextAlignmentRight;
|
|
|
_totalLabel.textColor = [UIColor hwColor:@"#818CA2"];
|
|
|
//_fileNamelabel.backgroundColor = [UIColor greenColor];
|
|
|
[whiteBgView addSubview:_totalLabel];
|
|
|
|
|
|
[_totalLabel mas_makeConstraints:^(MASConstraintMaker *make) {
|
|
|
- make.left.mas_equalTo(16);
|
|
|
+ make.right.mas_equalTo(-16);
|
|
|
make.width.mas_equalTo(butWidth);
|
|
|
make.top.mas_equalTo(_progressBgView.mas_bottom).offset(10);
|
|
|
}];
|
|
|
@@ -141,28 +142,29 @@
|
|
|
_usedlabel = [[UILabel alloc] init];
|
|
|
_usedlabel.font = curFont;
|
|
|
_usedlabel.textColor = [UIColor hwColor:@"#818CA2"];
|
|
|
- _usedlabel.textAlignment = NSTextAlignmentCenter;
|
|
|
+ //_usedlabel.textAlignment = NSTextAlignmentRight;
|
|
|
//_usedlabel.backgroundColor = [UIColor greenColor];
|
|
|
[whiteBgView addSubview:_usedlabel];
|
|
|
|
|
|
[_usedlabel mas_makeConstraints:^(MASConstraintMaker *make) {
|
|
|
- make.left.mas_equalTo(_totalLabel.mas_right);
|
|
|
+ //make.left.mas_equalTo(_totalLabel.mas_right);
|
|
|
+ make.left.mas_equalTo(16);
|
|
|
make.width.mas_equalTo(butWidth);
|
|
|
make.top.mas_equalTo(_progressBgView.mas_bottom).offset(10);
|
|
|
}];
|
|
|
|
|
|
- _unuselabel = [[UILabel alloc] init];
|
|
|
- _unuselabel.font = curFont;
|
|
|
- _unuselabel.textColor = [UIColor hwColor:@"#818CA2"];
|
|
|
- _unuselabel.textAlignment = NSTextAlignmentRight;
|
|
|
- //_unuselabel.backgroundColor = [UIColor greenColor];
|
|
|
- [whiteBgView addSubview:_unuselabel];
|
|
|
-
|
|
|
- [_unuselabel mas_makeConstraints:^(MASConstraintMaker *make) {
|
|
|
- make.right.mas_equalTo(-13);
|
|
|
- make.width.mas_equalTo(butWidth);
|
|
|
- make.top.mas_equalTo(_progressBgView.mas_bottom).offset(10);
|
|
|
- }];
|
|
|
+// _unuselabel = [[UILabel alloc] init];
|
|
|
+// _unuselabel.font = curFont;
|
|
|
+// _unuselabel.textColor = [UIColor hwColor:@"#818CA2"];
|
|
|
+// _unuselabel.textAlignment = NSTextAlignmentRight;
|
|
|
+// //_unuselabel.backgroundColor = [UIColor greenColor];
|
|
|
+// [whiteBgView addSubview:_unuselabel];
|
|
|
+//
|
|
|
+// [_unuselabel mas_makeConstraints:^(MASConstraintMaker *make) {
|
|
|
+// make.right.mas_equalTo(-13);
|
|
|
+// make.width.mas_equalTo(butWidth);
|
|
|
+// make.top.mas_equalTo(_progressBgView.mas_bottom).offset(10);
|
|
|
+// }];
|
|
|
|
|
|
}
|
|
|
|
|
|
@@ -224,12 +226,12 @@
|
|
|
}
|
|
|
_usedlabel.text = usedStr;
|
|
|
|
|
|
- NSString *unusedStr = [[NSString alloc] initWithFormat:@"%@%.2fGB",NSLocalizedString(@"NAS_disk_unuse_Space",nil),extraAvableSizeF];
|
|
|
- if(extraAvableSizeF > 1024){
|
|
|
- extraAvableSizeF = extraAvableSizeF/1024.0;
|
|
|
- unusedStr = [[NSString alloc] initWithFormat:@"%@%.2fTB",NSLocalizedString(@"NAS_disk_unuse_Space",nil),extraAvableSizeF];
|
|
|
- }
|
|
|
- _unuselabel.text = unusedStr;
|
|
|
+// NSString *unusedStr = [[NSString alloc] initWithFormat:@"%@%.2fGB",NSLocalizedString(@"NAS_disk_unuse_Space",nil),extraAvableSizeF];
|
|
|
+// if(extraAvableSizeF > 1024){
|
|
|
+// extraAvableSizeF = extraAvableSizeF/1024.0;
|
|
|
+// unusedStr = [[NSString alloc] initWithFormat:@"%@%.2fTB",NSLocalizedString(@"NAS_disk_unuse_Space",nil),extraAvableSizeF];
|
|
|
+// }
|
|
|
+// _unuselabel.text = unusedStr;
|
|
|
|
|
|
}
|
|
|
@end
|