Skip to content

Commit 90bdc47

Browse files
author
ccharlesren
committed
调整手动智能、自动智能,进度条件不缺失情况下,进度条位置偏移
文档:https://docs.qq.com/doc/DRWVqbnNJcHdJVHdB 2020.12.1 问题-4 遗漏问题 Change-Id: I4cf17b8bc8259d2607c5466f1d65223eab77c78b
1 parent 85e1e47 commit 90bdc47

File tree

3 files changed

+13
-4
lines changed

3 files changed

+13
-4
lines changed

Source/LinkApp/Classes/Module/Intelligent/Controller/TIoTIntelligentLogVC.m

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -265,7 +265,7 @@ - (void)requestDeviceAliasNameData:(NSDictionary *)dic semaphore:(dispatch_semap
265265
- (void)addEmptyIntelligentLogTipView {
266266
[self.view addSubview:self.emptyImageView];
267267
[self.emptyImageView mas_makeConstraints:^(MASConstraintMaker *make) {
268-
CGFloat kSpaceHeight = 100; //距离中心偏移量
268+
CGFloat kSpaceHeight = 70; //距离中心偏移量
269269
if ([TIoTUIProxy shareUIProxy].iPhoneX) {
270270
kSpaceHeight = 150;
271271
}

Source/LinkApp/Classes/Module/Intelligent/Controller/TIoTIntelligentVC.m

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -145,7 +145,7 @@ - (void)loadSceneList {
145145
- (void)addEmptyIntelligentDeviceTipView {
146146
[self.view addSubview:self.emptyImageView];
147147
[self.emptyImageView mas_makeConstraints:^(MASConstraintMaker *make) {
148-
CGFloat kSpaceHeight = 100; //距离中心偏移量
148+
CGFloat kSpaceHeight = 70; //距离中心偏移量
149149
if ([TIoTUIProxy shareUIProxy].iPhoneX) {
150150
kSpaceHeight = 150;
151151
}

Source/LinkApp/Classes/Module/Intelligent/View/TIoTChooseSliderValueView.m

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,7 @@ @interface TIoTChooseSliderValueView ()
4848
@property (nonatomic, strong) UIButton *lesserButton;//小于
4949

5050
@property (nonatomic, strong) NSString *compareValueString;
51+
@property (nonatomic, assign) CGFloat kReduceBtnY; //slider减号y高度
5152
@end
5253

5354
@implementation TIoTChooseSliderValueView
@@ -75,6 +76,8 @@ - (void)setupSubViewUI {
7576
CGFloat kCompareBtnWidht = 45;
7677
CGFloat kCompareBtnHeight = 28;
7778

79+
self.kReduceBtnY = (kViewHeight - kBottomViewHeight - kTopViewHeight)/2;
80+
7881
CGFloat kSliderWidth = kScreenWidth - kPadding*2 - kLeftButtonWithHeight*2 - kSliderLeftSpace*2;
7982
self.sliderWidth = kSliderWidth;
8083

@@ -133,8 +136,7 @@ - (void)setupSubViewUI {
133136
[self.sliderBackView addSubview:self.reduceButton];
134137
[self.reduceButton mas_makeConstraints:^(MASConstraintMaker *make) {
135138
make.left.equalTo(self.sliderBackView.mas_left).offset(kPadding);
136-
CGFloat kReduceBtnY = (kViewHeight - kBottomViewHeight - kTopViewHeight)/2+20;
137-
make.top.mas_equalTo(kReduceBtnY);
139+
make.top.mas_equalTo(self.kReduceBtnY+20);
138140
make.width.height.mas_equalTo(kLeftButtonWithHeight);
139141
}];
140142

@@ -420,6 +422,9 @@ - (void)drawRect:(CGRect)rect {
420422
self.equalButton.hidden = NO;
421423
self.greaterButton.hidden = NO;
422424
self.lesserButton.hidden = NO;
425+
[self.reduceButton mas_updateConstraints:^(MASConstraintMaker *make) {
426+
make.top.mas_equalTo(self.kReduceBtnY+20);
427+
}];
423428
NSString *opStr = self.conditionModel.Property.Op?:@"";
424429
if ([opStr isEqualToString:@"eq"]) { //条件操作符 eq 等于 ne 不等于 gt 大于 lt 小于 ge 大等于 le 小等于
425430
[self clickCompareButton:self.equalButton];
@@ -441,6 +446,10 @@ - (void)drawRect:(CGRect)rect {
441446
self.equalButton.hidden = YES;
442447
self.greaterButton.hidden = YES;
443448
self.lesserButton.hidden = YES;
449+
450+
[self.reduceButton mas_updateConstraints:^(MASConstraintMaker *make) {
451+
make.top.mas_equalTo(self.kReduceBtnY);
452+
}];
444453
}
445454
}
446455

0 commit comments

Comments
 (0)