热点连接流程修改
This commit is contained in:
@@ -30,8 +30,8 @@
|
||||
|
||||
@interface IQTitleBarButtonItem ()
|
||||
|
||||
@property(nonatomic, strong) UIView *titleView;
|
||||
@property(nonatomic, strong) UIButton *titleButton;
|
||||
@property(nullable, nonatomic, strong) UIView *titleView;
|
||||
@property(nullable, nonatomic, strong) UIButton *titleButton;
|
||||
|
||||
@end
|
||||
|
||||
@@ -48,7 +48,16 @@
|
||||
_titleButton = [UIButton buttonWithType:UIButtonTypeSystem];
|
||||
_titleButton.enabled = NO;
|
||||
_titleButton.titleLabel.numberOfLines = 3;
|
||||
[_titleButton setTitleColor:[UIColor colorWithRed:0.0 green:0.5 blue:1.0 alpha:1.0] forState:UIControlStateNormal];
|
||||
#if __IPHONE_OS_VERSION_MAX_ALLOWED >= 130000
|
||||
if (@available(iOS 13.0, *)) {
|
||||
[_titleButton setTitleColor:[UIColor systemBlueColor] forState:UIControlStateNormal];
|
||||
} else
|
||||
#endif
|
||||
{
|
||||
#if __IPHONE_OS_VERSION_MIN_REQUIRED < 130000
|
||||
[_titleButton setTitleColor:[UIColor colorWithRed:0.0 green:0.5 blue:1.0 alpha:1.0] forState:UIControlStateNormal];
|
||||
#endif
|
||||
}
|
||||
[_titleButton setTitleColor:[UIColor lightGrayColor] forState:UIControlStateDisabled];
|
||||
[_titleButton setBackgroundColor:[UIColor clearColor]];
|
||||
[_titleButton.titleLabel setTextAlignment:NSTextAlignmentCenter];
|
||||
@@ -56,7 +65,6 @@
|
||||
[self setTitleFont:[UIFont systemFontOfSize:13.0]];
|
||||
[_titleView addSubview:_titleButton];
|
||||
|
||||
#ifdef __IPHONE_11_0
|
||||
if (@available(iOS 11.0, *))
|
||||
{
|
||||
CGFloat layoutDefaultLowPriority = UILayoutPriorityDefaultLow-1;
|
||||
@@ -81,7 +89,6 @@
|
||||
[_titleView addConstraints:@[top,bottom,leading,trailing]];
|
||||
}
|
||||
else
|
||||
#endif
|
||||
{
|
||||
_titleView.autoresizingMask = UIViewAutoresizingFlexibleWidth|UIViewAutoresizingFlexibleHeight;
|
||||
_titleButton.autoresizingMask = UIViewAutoresizingFlexibleWidth|UIViewAutoresizingFlexibleHeight;
|
||||
@@ -121,7 +128,16 @@
|
||||
-(void)setSelectableTitleColor:(UIColor*)selectableTitleColor
|
||||
{
|
||||
_selectableTitleColor = selectableTitleColor;
|
||||
[_titleButton setTitleColor:_selectableTitleColor?:[UIColor colorWithRed:0.0 green:0.5 blue:1.0 alpha:1.0] forState:UIControlStateNormal];
|
||||
#if __IPHONE_OS_VERSION_MAX_ALLOWED >= 130000
|
||||
if (@available(iOS 13.0, *)) {
|
||||
[_titleButton setTitleColor:_selectableTitleColor?:[UIColor systemBlueColor] forState:UIControlStateNormal];
|
||||
} else
|
||||
#endif
|
||||
{
|
||||
#if __IPHONE_OS_VERSION_MIN_REQUIRED < 130000
|
||||
[_titleButton setTitleColor:_selectableTitleColor?:[UIColor colorWithRed:0.0 green:0.5 blue:1.0 alpha:1.0] forState:UIControlStateNormal];
|
||||
#endif
|
||||
}
|
||||
}
|
||||
|
||||
-(void)setInvocation:(NSInvocation *)invocation
|
||||
|
||||
Reference in New Issue
Block a user