fixed: 1.适配小屏幕机型

feature: 1.忘记密码新增语音和短信验证码切换功能
This commit is contained in:
jiangxuefei718 2019-03-14 08:41:00 +08:00
parent 5746d392a3
commit 91aee9dac1
35 changed files with 293 additions and 129 deletions

BIN
.DS_Store vendored

Binary file not shown.

View File

@ -364,6 +364,10 @@
3DD7AB9A21E474940064856A /* AsyncSocket.m in Sources */ = {isa = PBXBuildFile; fileRef = 3DD7AB9221E474930064856A /* AsyncSocket.m */; };
3DD7AB9B21E474940064856A /* GCDAsyncUdpSocket.m in Sources */ = {isa = PBXBuildFile; fileRef = 3DD7AB9521E474930064856A /* GCDAsyncUdpSocket.m */; };
3DD7AB9C21E474940064856A /* GCDAsyncSocket.m in Sources */ = {isa = PBXBuildFile; fileRef = 3DD7AB9621E474930064856A /* GCDAsyncSocket.m */; };
402591952238D91400CE4900 /* UINavigationController+Config.h in Headers */ = {isa = PBXBuildFile; fileRef = 402591932238D91400CE4900 /* UINavigationController+Config.h */; };
402591962238D91400CE4900 /* UINavigationController+Config.m in Sources */ = {isa = PBXBuildFile; fileRef = 402591942238D91400CE4900 /* UINavigationController+Config.m */; };
404D7CEA2238CF77005655F5 /* UIViewController+Swizzling.m in Sources */ = {isa = PBXBuildFile; fileRef = 404D7CE82238CF77005655F5 /* UIViewController+Swizzling.m */; };
404D7CEB2238CF77005655F5 /* UIViewController+Swizzling.h in Headers */ = {isa = PBXBuildFile; fileRef = 404D7CE92238CF77005655F5 /* UIViewController+Swizzling.h */; };
880707451DDD3EF50076F65A /* P2PShareView1Cell.m in Sources */ = {isa = PBXBuildFile; fileRef = 880707431DDD3EF50076F65A /* P2PShareView1Cell.m */; };
880707461DDD3EF50076F65A /* P2PShareView1Cell.xib in Resources */ = {isa = PBXBuildFile; fileRef = 880707441DDD3EF50076F65A /* P2PShareView1Cell.xib */; };
8807074A1DDD40B40076F65A /* P2PShareViewsec2Cell.m in Sources */ = {isa = PBXBuildFile; fileRef = 880707481DDD40B40076F65A /* P2PShareViewsec2Cell.m */; };
@ -3174,6 +3178,10 @@
3DD7AB9621E474930064856A /* GCDAsyncSocket.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = GCDAsyncSocket.m; sourceTree = "<group>"; };
3DD7AB9721E474930064856A /* GCDAsyncUdpSocket.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = GCDAsyncUdpSocket.h; sourceTree = "<group>"; };
3DD7AB9821E474930064856A /* GCDAsyncSocket.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = GCDAsyncSocket.h; sourceTree = "<group>"; };
402591932238D91400CE4900 /* UINavigationController+Config.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = "UINavigationController+Config.h"; sourceTree = "<group>"; };
402591942238D91400CE4900 /* UINavigationController+Config.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = "UINavigationController+Config.m"; sourceTree = "<group>"; };
404D7CE82238CF77005655F5 /* UIViewController+Swizzling.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "UIViewController+Swizzling.m"; sourceTree = "<group>"; };
404D7CE92238CF77005655F5 /* UIViewController+Swizzling.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "UIViewController+Swizzling.h"; sourceTree = "<group>"; };
880707421DDD3EF50076F65A /* P2PShareView1Cell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = P2PShareView1Cell.h; sourceTree = "<group>"; };
880707431DDD3EF50076F65A /* P2PShareView1Cell.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = P2PShareView1Cell.m; sourceTree = "<group>"; };
880707441DDD3EF50076F65A /* P2PShareView1Cell.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = P2PShareView1Cell.xib; sourceTree = "<group>"; };
@ -14401,6 +14409,10 @@
isa = PBXGroup;
children = (
E5C644C0206BBD7100C558D5 /* CommonMacros.h */,
404D7CE92238CF77005655F5 /* UIViewController+Swizzling.h */,
404D7CE82238CF77005655F5 /* UIViewController+Swizzling.m */,
402591932238D91400CE4900 /* UINavigationController+Config.h */,
402591942238D91400CE4900 /* UINavigationController+Config.m */,
);
path = Common;
sourceTree = "<group>";
@ -14486,6 +14498,7 @@
3D1C5040221A9EDE0096AE43 /* version.h in Headers */,
3D1C50AF221A9EDF0096AE43 /* YFonc.h in Headers */,
3D1C512B221A9EE10096AE43 /* IfishCameraRecordfirstCell.h in Headers */,
402591952238D91400CE4900 /* UINavigationController+Config.h in Headers */,
3D1C5124221A9EE00096AE43 /* IfishCameraRecordThirdCell.h in Headers */,
3D1C5045221A9EDE0096AE43 /* sha.h in Headers */,
3D1C5057221A9EDF0096AE43 /* opt.h in Headers */,
@ -14575,6 +14588,7 @@
3D1C50AD221A9EDF0096AE43 /* FXBlurView.h in Headers */,
3D1C5043221A9EDE0096AE43 /* base64.h in Headers */,
3D1C504B221A9EDF0096AE43 /* crc.h in Headers */,
404D7CEB2238CF77005655F5 /* UIViewController+Swizzling.h in Headers */,
3D1C5065221A9EDF0096AE43 /* avassert.h in Headers */,
);
runOnlyForDeploymentPostprocessing = 0;
@ -14650,6 +14664,9 @@
CreatedOnToolsVersion = 7.0;
ProvisioningStyle = Manual;
SystemCapabilities = {
com.apple.AccessWiFi = {
enabled = 1;
};
com.apple.BackgroundModes = {
enabled = 1;
};
@ -16649,6 +16666,7 @@
881672051EA5DE2B00BEBF23 /* UMComSegmentedControl.m in Sources */,
88F5EFC91D48D08100CC7CAF /* JHRefreshFooterView.m in Sources */,
88645B161E83B7EC00234DB4 /* IfishInfoDetailContentViewCell.m in Sources */,
404D7CEA2238CF77005655F5 /* UIViewController+Swizzling.m in Sources */,
881672001EA5DE2B00BEBF23 /* UMImagePickerController.m in Sources */,
88C598951EA0605600BDC812 /* KebordExternAddTextInputView.m in Sources */,
883E788F1D48A5E50030E075 /* InfoXingBieCell.m in Sources */,
@ -17097,6 +17115,7 @@
886FB1B01E5AA02400256332 /* FIshDocsection1TableView2Cell.m in Sources */,
3D1C5103221A9EE00096AE43 /* YooseeNextConnectViewController.mm in Sources */,
88602A3C1E10BC3500F3DB5D /* NIMCellLayoutConfig.m in Sources */,
402591962238D91400CE4900 /* UINavigationController+Config.m in Sources */,
882C85A61EB03759001CC414 /* GoldConvertDetailViewCell.m in Sources */,
881477EA1E711B4D00BFB79C /* IfishTaskViewCell.m in Sources */,
E5317A1621188F8A0014AFDD /* RestartDeviceModel.m in Sources */,
@ -17410,7 +17429,7 @@
CLANG_CXX_LIBRARY = "compiler-default";
CODE_SIGN_ENTITLEMENTS = Ifish/Ifish.entitlements;
CODE_SIGN_IDENTITY = "iPhone Developer";
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer: guowu ouyang (Q5YLXZSN4A)";
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
CODE_SIGN_STYLE = Manual;
DEVELOPMENT_TEAM = "";
ENABLE_BITCODE = NO;
@ -17505,9 +17524,9 @@
"-ObjC",
"-Istdc++",
);
PRODUCT_BUNDLE_IDENTIFIER = com.shyuying.Ifish8;
PRODUCT_BUNDLE_IDENTIFIER = com.pingan.shanghu;
PRODUCT_NAME = "$(TARGET_NAME)";
PROVISIONING_PROFILE = "fde698f5-2eb6-468d-9f69-0dee117d218e";
PROVISIONING_PROFILE = "";
PROVISIONING_PROFILE_SPECIFIER = "";
TARGETED_DEVICE_FAMILY = 1;
USER_HEADER_SEARCH_PATHS = "";
@ -17523,7 +17542,7 @@
CLANG_CXX_LIBRARY = "compiler-default";
CODE_SIGN_ENTITLEMENTS = Ifish/Ifish.entitlements;
CODE_SIGN_IDENTITY = "iPhone Developer";
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Distribution: Shanghai Yu Ying Technology Co., Ltd. (WFX8GD5HFX)";
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
CODE_SIGN_STYLE = Manual;
DEVELOPMENT_TEAM = "";
ENABLE_BITCODE = NO;
@ -17618,7 +17637,7 @@
"-ObjC",
"-Istdc++",
);
PRODUCT_BUNDLE_IDENTIFIER = com.shyuying.Ifish8;
PRODUCT_BUNDLE_IDENTIFIER = com.pingan.shanghu;
PRODUCT_NAME = "$(TARGET_NAME)";
PROVISIONING_PROFILE = "eeefa590-8286-4301-b6e5-f1eeee0de64f";
PROVISIONING_PROFILE_SPECIFIER = "";

View File

@ -1,5 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict/>
<dict>
<key>BuildSystemType</key>
<string>Original</string>
</dict>
</plist>

View File

@ -10,5 +10,12 @@
#define CommonMacros_h
#define is_iPhone_X ([UIScreen instancesRespondToSelector:@selector(currentMode)] ? CGSizeEqualToSize(CGSizeMake(1125, 2436), [[UIScreen mainScreen] currentMode].size) : NO)
#define STATUS_BAR_HEIGHT [[UIApplication sharedApplication] statusBarFrame].size.height
#define TOP_HEIGHT (STATUS_BAR_HEIGHT + 44)
// 屏幕宽度
#define kScreenWidth ((CGRectGetWidth([UIScreen mainScreen].bounds) > CGRectGetHeight([UIScreen mainScreen].bounds))?(CGRectGetHeight([UIScreen mainScreen].bounds)):(CGRectGetWidth([UIScreen mainScreen].bounds)))
// 屏幕高度
#define kScreenHeight ((CGRectGetWidth([UIScreen mainScreen].bounds) > CGRectGetHeight([UIScreen mainScreen].bounds))?(CGRectGetWidth([UIScreen mainScreen].bounds)):(CGRectGetHeight([UIScreen mainScreen].bounds)))
#endif /* CommonMacros_h */

View File

@ -0,0 +1,17 @@
//
// UINavigationController+Config.h
// Ifish
//
// Created by JiangXuefei on 2019/3/13.
// Copyright © 2019年 lianlian. All rights reserved.
//
#import <UIKit/UIKit.h>
NS_ASSUME_NONNULL_BEGIN
@interface UINavigationController (Config)
@end
NS_ASSUME_NONNULL_END

View File

@ -0,0 +1,17 @@
//
// UINavigationController+Config.m
// Ifish
//
// Created by JiangXuefei on 2019/3/13.
// Copyright © 2019 lianlian. All rights reserved.
//
#import "UINavigationController+Config.h"
@implementation UINavigationController (Config)
+ (void)initialize {
[[UINavigationBar appearance] setTranslucent:NO];
}
@end

View File

@ -0,0 +1,17 @@
//
// UIViewController+Swizzling.h
// IfishTests
//
// Created by JiangXuefei on 2019/3/13.
// Copyright © 2019年 lianlian. All rights reserved.
//
#import <UIKit/UIKit.h>
NS_ASSUME_NONNULL_BEGIN
@interface UIViewController (Swizzling)
@end
NS_ASSUME_NONNULL_END

View File

@ -0,0 +1,29 @@
//
// UIViewController+Swizzling.m
// IfishTests
//
// Created by JiangXuefei on 2019/3/13.
// Copyright © 2019 lianlian. All rights reserved.
//
#import "UIViewController+Swizzling.h"
#import <objc/runtime.h>
@implementation UIViewController (Swizzling)
+ (void)load
{
#ifdef DEBUG
Method viewWillAppear = class_getInstanceMethod(self, @selector(viewWillAppear:));
Method logViewWillAppear = class_getInstanceMethod(self, @selector(logViewWillAppear:));
method_exchangeImplementations(viewWillAppear, logViewWillAppear);
#endif
}
- (void)logViewWillAppear:(BOOL)animated
{
NSLog(@"========>%@ will appear",NSStringFromClass([self class]));
[self logViewWillAppear:animated];
}
@end

View File

@ -4,5 +4,7 @@
<dict>
<key>aps-environment</key>
<string>development</string>
<key>com.apple.developer.networking.wifi-info</key>
<true/>
</dict>
</plist>

View File

@ -77,6 +77,7 @@
[closeButon addTarget:self action:@selector(onClickClose) forControlEvents:UIControlEventTouchUpInside];
closeButon.frame = CGRectMake(0.f, 0.f, 22.f, 22.f);
UIBarButtonItem *closeItem = [[UIBarButtonItem alloc] initWithCustomView:closeButon];
[closeButon setContentEdgeInsets:UIEdgeInsetsMake(0, 10, 0, -10)];
[self.navigationItem setLeftBarButtonItem:closeItem];
}

View File

@ -213,7 +213,7 @@
}
dispatch_async(dispatch_get_main_queue(), ^{
//
NSLog(@"____%@",strTime);
// NSLog(@"____%@",strTime);
[timeBtn setTitle:[NSString stringWithFormat:@"%@秒",strTime] forState:UIControlStateNormal];
//timeBtn.backgroundColor=[UIColor lightGrayColor];

View File

@ -20,18 +20,14 @@
// Do any additional setup after loading the view.
[self initNav];
self.view.backgroundColor = TABLE_BACKGROUD_COLOR;
}
-(void)viewWillAppear:(BOOL)animated{
[super viewWillAppear:animated];
[self.navigationController.navigationBar resetBackgroundImage];
}
-(void)viewWillDisappear:(BOOL)animated{
[super viewWillDisappear:animated];
}
@ -57,9 +53,10 @@
_bakbutton = [UIButton buttonWithType:UIButtonTypeCustom];
_bakbutton.frame = CGRectMake(0,0,48,44);
[_bakbutton setImage:[UIImage imageNamed:@"back_btn"] forState:UIControlStateNormal];
_bakbutton.contentHorizontalAlignment = UIControlContentHorizontalAlignmentLeft;
_bakbutton.contentHorizontalAlignment = UIControlContentHorizontalAlignmentLeft;
[_bakbutton addTarget: self action: @selector(goBackAction) forControlEvents: UIControlEventTouchUpInside];
[_bakbutton setContentEdgeInsets:UIEdgeInsetsMake(0, 10, 0, -10)];
_back=[[UIBarButtonItem alloc] initWithCustomView:_bakbutton];
self.navigationItem.leftBarButtonItem=_back;
@ -106,11 +103,8 @@
#pragma mark -
-(BOOL)prefersStatusBarHidden
{
-(BOOL)prefersStatusBarHidden{
return NO;
}
//
- (UIStatusBarStyle)preferredStatusBarStyle
@ -147,9 +141,6 @@
-(UIInterfaceOrientationMask)supportedInterfaceOrientations{
return UIInterfaceOrientationMaskPortrait|UIInterfaceOrientationMaskLandscapeRight;
}
#pragma mark
@ -157,7 +148,6 @@
return UIInterfaceOrientationPortrait;
}
#pragma mark -
-(void)willAnimateRotationToInterfaceOrientation:(UIInterfaceOrientation)toInterfaceOrientation duration:(NSTimeInterval)duration
{

View File

@ -48,8 +48,8 @@
_bakbutton = [UIButton buttonWithType:UIButtonTypeCustom];
_bakbutton.frame = CGRectMake(0,0,48,44);
[_bakbutton setImage:[UIImage imageNamed:@"back_btn"] forState:UIControlStateNormal];
_bakbutton.contentHorizontalAlignment = UIControlContentHorizontalAlignmentLeft;
[_bakbutton setContentEdgeInsets:UIEdgeInsetsMake(0, 10, 0, -10)];
[_bakbutton addTarget: self action: @selector(goBackAction) forControlEvents: UIControlEventTouchUpInside];
_back=[[UIBarButtonItem alloc] initWithCustomView:_bakbutton];

View File

@ -21,8 +21,17 @@
}
-(void)setNav{
UIBarButtonItem*back=[[UIBarButtonItem alloc] initWithImage:[[UIImage imageNamed:@"back_btn"] imageWithRenderingMode:UIImageRenderingModeAlwaysOriginal] style:UIBarButtonItemStyleDone target:self action:@selector(goBackAction)];
self.navigationItem.leftBarButtonItem=back;
UIButton *back = [UIButton buttonWithType:UIButtonTypeCustom];
back.frame = CGRectMake(0,0,48,44);
[back setImage:[UIImage imageNamed:@"back_btn"] forState:UIControlStateNormal];
// [_bakbutton setBackgroundImage:[UIImage imageNamed:@"back_btn"] forState:UIControlStateNormal];
[back addTarget: self action: @selector(goBackAction) forControlEvents: UIControlEventTouchUpInside];
[back setContentEdgeInsets:UIEdgeInsetsMake(0, 10, 0, -10)];
back.contentHorizontalAlignment = UIControlContentHorizontalAlignmentLeft;
UIBarButtonItem * backItem=[[UIBarButtonItem alloc] initWithCustomView:back];
self.navigationItem.leftBarButtonItem=backItem;
}
- (void)addTitleViewWithTitle:(NSString *)title{

View File

@ -133,9 +133,11 @@
[self.openDrawerButton setImage:hamburger forState:UIControlStateNormal];
//[self.openDrawerButton addTarget:self action:@selector(openDrawer:) forControlEvents:UIControlEventTouchUpInside];
[self.openDrawerButton addTarget:self action:@selector(leftBtnGoBackAction) forControlEvents:UIControlEventTouchUpInside];
self.openDrawerButton.contentHorizontalAlignment = UIControlContentHorizontalAlignmentLeft;
[self.openDrawerButton setContentEdgeInsets:UIEdgeInsetsMake(0, 10, 0, -10)];
UIBarButtonItem * backItem=[[UIBarButtonItem alloc] initWithCustomView:self.openDrawerButton];
UIBarButtonItem *leftItem=[[UIBarButtonItem alloc] initWithImage:hamburger style:UIBarButtonItemStylePlain target:self action:@selector(leftBtnGoBackAction)];
self.navigationItem.leftBarButtonItem = leftItem;
self.navigationItem.leftBarButtonItem=backItem;
//

View File

@ -222,7 +222,8 @@ NS_ENUM(NSInteger,deviceType){
[bakbutton addTarget: self action: @selector(goBackAction) forControlEvents: UIControlEventTouchUpInside];
bakbutton.contentHorizontalAlignment = UIControlContentHorizontalAlignmentLeft;
[bakbutton setContentEdgeInsets:UIEdgeInsetsMake(0, 10, 0, -10)];
UIBarButtonItem *back=[[UIBarButtonItem alloc] initWithCustomView:bakbutton];
self.navigationItem.leftBarButtonItem=back;
self.title = @"切换设备";

View File

@ -20,8 +20,17 @@
// Do any additional setup after loading the view from its nib.
self.title=@"修改名称";
self.navigationItem.rightBarButtonItem=[[UIBarButtonItem alloc]initWithTitle:@"保存" style:0 target:self action:@selector(clickModifyName)];
UIImage *hamburger = [[UIImage imageNamed:@"back_btn"] imageWithRenderingMode:UIImageRenderingModeAlwaysOriginal];
self.navigationItem.leftBarButtonItem=[[UIBarButtonItem alloc]initWithImage:hamburger style:0 target:self action:@selector(clickBack)];
UIButton *back = [UIButton buttonWithType:UIButtonTypeCustom];
back.frame = CGRectMake(0,0,48,44);
[back setImage:[UIImage imageNamed:@"back_btn"] forState:UIControlStateNormal];
// [_bakbutton setBackgroundImage:[UIImage imageNamed:@"back_btn"] forState:UIControlStateNormal];
[back addTarget: self action: @selector(clickBack) forControlEvents: UIControlEventTouchUpInside];
[back setContentEdgeInsets:UIEdgeInsetsMake(0, 10, 0, -10)];
back.contentHorizontalAlignment = UIControlContentHorizontalAlignmentLeft;
UIBarButtonItem * backItem=[[UIBarButtonItem alloc] initWithCustomView:back];
self.navigationItem.leftBarButtonItem=backItem;
}
-(void)clickBack{

View File

@ -261,8 +261,17 @@
[self creatRefreshView];
[self header];
//
UIImage *hamburger = [[UIImage imageNamed:@"back_btn"] imageWithRenderingMode:UIImageRenderingModeAlwaysOriginal];
self.navigationItem.leftBarButtonItem=[[UIBarButtonItem alloc]initWithImage:hamburger style:0 target:self action:@selector(clickBack)];
UIButton *back = [UIButton buttonWithType:UIButtonTypeCustom];
back.frame = CGRectMake(0,0,48,44);
[back setImage:[UIImage imageNamed:@"back_btn"] forState:UIControlStateNormal];
// [_bakbutton setBackgroundImage:[UIImage imageNamed:@"back_btn"] forState:UIControlStateNormal];
[back addTarget: self action: @selector(clickBack) forControlEvents: UIControlEventTouchUpInside];
back.contentHorizontalAlignment = UIControlContentHorizontalAlignmentLeft;
[back setContentEdgeInsets:UIEdgeInsetsMake(0, 10, 0, -10)];
UIBarButtonItem * backItem=[[UIBarButtonItem alloc] initWithCustomView:back];
self.navigationItem.leftBarButtonItem=backItem;
self.navigationItem.rightBarButtonItem=[[UIBarButtonItem alloc] initWithImage:[UIImage imageNamed:@"ifishnav_dropview_list"] style:0 target:self action:@selector(clickMoreBtn)];
}

View File

@ -159,7 +159,7 @@ BOOL cerViewFormRootVC;
-(void)creatTab{
self.tableView = [[UITableView alloc] initWithFrame:CGRectMake(0,0, kScreenSize.width,kScreenSize.height - 49 ) style:UITableViewStylePlain];
self.tableView = [[UITableView alloc] initWithFrame:CGRectMake(0,0, kScreenSize.width,kScreenSize.height - 49 -TOP_HEIGHT ) style:UITableViewStylePlain];
self.tableView.delegate = self;
self.tableView.dataSource = self;
self.tableView.scrollEnabled = YES;

View File

@ -44,6 +44,7 @@
self.bakbutton.frame = CGRectMake(0,0,48,44);
[self.bakbutton setImage:[UIImage imageNamed:@"arrow_b"] forState:UIControlStateNormal];
[self.bakbutton addTarget: self action: @selector(goBackAction) forControlEvents: UIControlEventTouchUpInside];
[self.bakbutton setContentEdgeInsets:UIEdgeInsetsMake(0, 10, 0, -10)];
self.back=[[UIBarButtonItem alloc] initWithCustomView:self.bakbutton];
self.navigationItem.leftBarButtonItem=self.back;

View File

@ -146,8 +146,10 @@ NIMContactSelectDelegate
[bakbutton setImage:[UIImage imageNamed:@"back_btn"] forState:UIControlStateNormal];
[bakbutton addTarget: self action: @selector(goBackAction) forControlEvents: UIControlEventTouchUpInside];
[bakbutton setContentEdgeInsets:UIEdgeInsetsMake(0, 10, 0, -10)];
bakbutton.contentHorizontalAlignment = UIControlContentHorizontalAlignmentLeft;
UIBarButtonItem *back=[[UIBarButtonItem alloc] initWithCustomView:bakbutton];
self.navigationItem.leftBarButtonItem=back;
UILabel*labe=[[UILabel alloc]initWithFrame:CGRectMake(0, 0, 60, 44)];
labe.text=[self sessionTitle];;

View File

@ -94,7 +94,8 @@
[bakbutton setImage:[UIImage imageNamed:@"back_btn"] forState:UIControlStateNormal];
[bakbutton addTarget: self action: @selector(backAction) forControlEvents: UIControlEventTouchUpInside];
bakbutton.contentHorizontalAlignment = UIControlContentHorizontalAlignmentLeft;
[bakbutton setContentEdgeInsets:UIEdgeInsetsMake(0, 10, 0, -10)];
UIBarButtonItem *backTem=[[UIBarButtonItem alloc] initWithCustomView:bakbutton];
self.navigationItem.leftBarButtonItem=backTem;
[self addTitleViewWithTitle:@"消息"];

View File

@ -1,11 +1,11 @@
<?xml version="1.0" encoding="UTF-8"?>
<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="14113" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" colorMatched="YES">
<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="14460.31" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" colorMatched="YES">
<device id="retina4_7" orientation="portrait">
<adaptation id="fullscreen"/>
</device>
<dependencies>
<deployment identifier="iOS"/>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="14088"/>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="14460.20"/>
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
</dependencies>
<objects>
@ -18,7 +18,7 @@
<rect key="frame" x="0.0" y="0.0" width="371" height="258.5"/>
<autoresizingMask key="autoresizingMask"/>
<subviews>
<imageView userInteractionEnabled="NO" contentMode="center" horizontalHuggingPriority="251" verticalHuggingPriority="251" translatesAutoresizingMaskIntoConstraints="NO" id="bYx-Sh-9R0">
<imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" translatesAutoresizingMaskIntoConstraints="NO" id="bYx-Sh-9R0">
<rect key="frame" x="0.0" y="0.0" width="371" height="259"/>
</imageView>
</subviews>

View File

@ -104,21 +104,17 @@ extern BOOL isfromCameraView;
});
});
}
-(void)creatTab{
self.tableView = [[UITableView alloc] initWithFrame:CGRectMake(0,0,self.view.frame.size.width,self.view.frame.size.height) style:UITableViewStyleGrouped];
self.tableView = [[UITableView alloc] initWithFrame:CGRectMake(0,0,kScreenWidth,kScreenHeight-TOP_HEIGHT) style:UITableViewStylePlain];
self.tableView.delegate = self;
self.tableView.dataSource = self;
self.tableView.estimatedRowHeight = 0;
self.tableView.estimatedSectionFooterHeight = 0;
self.tableView.estimatedSectionHeaderHeight = 0;
self.tableView.separatorStyle = UITableViewCellSeparatorStyleNone;
self.tableView.showsVerticalScrollIndicator = NO;
self.tableView.backgroundColor = [UIColor whiteColor];
@ -149,21 +145,7 @@ extern BOOL isfromCameraView;
}
-(CGFloat)tableView:(UITableView *)tableView heightForRowAtIndexPath:(NSIndexPath *)indexPath{
if(self.view.frame.size.width<=340.0){
return self.view.frame.size.width*0.304;
}
return self.view.frame.size.width*0.504;
}
-(CGFloat)tableView:(UITableView *)tableView heightForHeaderInSection:(NSInteger)section{
return 0.1;
}
-(CGFloat)tableView:(UITableView *)tableView heightForFooterInSection:(NSInteger)section{
return 0.1;
return 378/2.0;
}
- (void)didReceiveMemoryWarning {

View File

@ -730,7 +730,7 @@
-(void)viewWillAppear:(BOOL)animated{
[super viewWillAppear:animated];
self.navigationController.navigationBar.hidden = YES;
//
[self.navigationController
.navigationBar setClearNav];
@ -1206,6 +1206,7 @@
-(void)viewWillDisappear:(BOOL)animated{
[super viewWillDisappear:animated];
[self.view hideToastActivity];
self.navigationController.navigationBar.hidden = NO;
[self.navigationController.navigationBar cnReset];
}
@ -1214,8 +1215,8 @@
-(void)pushWiFiConnectVC{
self.hidesBottomBarWhenPushed = YES;
IfishBindDeviceSelectViewController *connectVC=[[IfishBindDeviceSelectViewController alloc]init];
self.hidesBottomBarWhenPushed = YES;
[self.navigationController pushViewController:connectVC animated:YES];
self.hidesBottomBarWhenPushed = NO;

View File

@ -473,6 +473,8 @@
leftBtn.frame = CGRectMake(0, 0, 47,44);
[leftBtn setImage:[UIImage imageNamed:@"back_btn"] forState:UIControlStateNormal];
[leftBtn addTarget: self action: @selector(btnClickToBack:) forControlEvents: UIControlEventTouchUpInside];
leftBtn.contentHorizontalAlignment = UIControlContentHorizontalAlignmentLeft;
[leftBtn setContentEdgeInsets:UIEdgeInsetsMake(0, 10, 0, -10)];
UIBarButtonItem * lbbItem=[[UIBarButtonItem alloc]initWithCustomView:leftBtn];
self.navigationItem.leftBarButtonItem=lbbItem;
//

View File

@ -40,9 +40,9 @@
back.frame = CGRectMake(0,0,48,44);
[back setImage:[UIImage imageNamed:@"back_btn"] forState:UIControlStateNormal];
// [_bakbutton setBackgroundImage:[UIImage imageNamed:@"back_btn"] forState:UIControlStateNormal];
[back addTarget: self action: @selector(goBackAction) forControlEvents: UIControlEventTouchUpInside];
back.contentHorizontalAlignment = UIControlContentHorizontalAlignmentLeft;
[back setContentEdgeInsets:UIEdgeInsetsMake(0, 10, 0, -10)];
UIBarButtonItem * backItem=[[UIBarButtonItem alloc] initWithCustomView:back];

View File

@ -113,7 +113,8 @@ typedef NS_ENUM(NSInteger,lodingViewdissMissStyle) {
-(UILabel *)redTipLable{
if (_redTipLable==nil) {
_redTipLable=[[UILabel alloc]initWithFrame:CGRectMake(19, 165, 100, 10)];
CGFloat y = CGRectGetMaxY(self.wifiSecFiled.frame) + 5;
_redTipLable=[[UILabel alloc]initWithFrame:CGRectMake(19, y, 100, 10)];
_redTipLable.text=@"(暂不支持5G网络请使用2.4G网络)";
_redTipLable.font=[UIFont systemFontOfSize:13];
_redTipLable.textColor=[UIColor redColor];
@ -576,12 +577,7 @@ typedef NS_ENUM(NSInteger,lodingViewdissMissStyle) {
//967/1018/ 0.95
CGFloat percentHbiW = 0.117 ;//5s 35/300
CGFloat y;
if (is_iPhone_X) {
y = 20 + 88;
} else {
y = 20 + 64;
}
CGFloat y = 20;
self.nodImg= [[UIImageView alloc] initWithFrame:CGRectMake(5, y,12, 12)];
self.nodImg.image = [UIImage imageNamed:@"linkingdevice_point"];
[self.view addSubview:self.nodImg];

View File

@ -512,12 +512,11 @@ const CGFloat ktkDefaultToolbarHeight = 49;
back.frame = CGRectMake(0,0,48,44);
[back setImage:[UIImage imageNamed:@"back_btn"] forState:UIControlStateNormal];
// [_bakbutton setBackgroundImage:[UIImage imageNamed:@"back_btn"] forState:UIControlStateNormal];
back.contentHorizontalAlignment = UIControlContentHorizontalAlignmentLeft;
[back addTarget: self action: @selector(goBackAction) forControlEvents: UIControlEventTouchUpInside];
[back setContentEdgeInsets:UIEdgeInsetsMake(0, 10, 0, -10)];
UIBarButtonItem * backItem=[[UIBarButtonItem alloc] initWithCustomView:back];
self.navigationItem.leftBarButtonItem=backItem;

View File

@ -159,7 +159,7 @@
//label
UILabel * labIntroudction= [[UILabel alloc] init];
labIntroudction.backgroundColor = [UIColor clearColor];
labIntroudction.frame=CGRectMake(0, 64+(heih-64-50*widthRate)/2, DeviceMaxWidth, 50*widthRate);
labIntroudction.frame=CGRectMake(0, (heih-64-50*widthRate)/2, DeviceMaxWidth, 50*widthRate);
labIntroudction.textAlignment = NSTextAlignmentCenter;
labIntroudction.textColor=[UIColor whiteColor];
labIntroudction.text=@"将二维码置于矩形方框内";

View File

@ -60,7 +60,9 @@
_bakbutton.frame = CGRectMake(0, 0, 47,44);
[_bakbutton setImage:[UIImage imageNamed:@"back_btn"] forState:UIControlStateNormal];
[_bakbutton addTarget: self action: @selector(backButtonEvent) forControlEvents: UIControlEventTouchUpInside];
[_bakbutton setContentEdgeInsets:UIEdgeInsetsMake(0, 10, 0, -10)];
_bakbutton.contentHorizontalAlignment = UIControlContentHorizontalAlignmentLeft;
UIBarButtonItem * lbbItem=[[UIBarButtonItem alloc]initWithCustomView:_bakbutton];
self.navigationItem.leftBarButtonItem=lbbItem;

View File

@ -61,8 +61,17 @@
fiveTapGesture.numberOfTapsRequired = 5;
[self.containerView addGestureRecognizer:fiveTapGesture];
UIImage *hamburger = [[UIImage imageNamed:@"back_btn"] imageWithRenderingMode:UIImageRenderingModeAlwaysOriginal];
self.navigationItem.leftBarButtonItem=[[UIBarButtonItem alloc]initWithImage:hamburger style:0 target:self action:@selector(clickBack)];
UIButton *back = [UIButton buttonWithType:UIButtonTypeCustom];
back.frame = CGRectMake(0,0,48,44);
[back setImage:[UIImage imageNamed:@"back_btn"] forState:UIControlStateNormal];
// [_bakbutton setBackgroundImage:[UIImage imageNamed:@"back_btn"] forState:UIControlStateNormal];
back.contentHorizontalAlignment = UIControlContentHorizontalAlignmentLeft;
[back addTarget: self action: @selector(clickBack) forControlEvents: UIControlEventTouchUpInside];
[back setContentEdgeInsets:UIEdgeInsetsMake(0, 10, 0, -10)];
back.contentHorizontalAlignment = UIControlContentHorizontalAlignmentLeft;
UIBarButtonItem * backItem=[[UIBarButtonItem alloc] initWithCustomView:back];
self.navigationItem.leftBarButtonItem=backItem;
}
-(void)clickBack{

View File

@ -1,11 +1,11 @@
<?xml version="1.0" encoding="UTF-8"?>
<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="14113" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" colorMatched="YES">
<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="14460.31" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" colorMatched="YES">
<device id="retina4_7" orientation="portrait">
<adaptation id="fullscreen"/>
</device>
<dependencies>
<deployment identifier="iOS"/>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="14088"/>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="14460.20"/>
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
</dependencies>
<objects>
@ -29,23 +29,23 @@
<rect key="frame" x="0.0" y="0.0" width="375" height="667"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews>
<textField opaque="NO" clipsSubviews="YES" contentMode="scaleToFill" fixedFrame="YES" contentHorizontalAlignment="left" contentVerticalAlignment="center" placeholder=" 请输入WiFi密码" minimumFontSize="17" clearButtonMode="whileEditing" translatesAutoresizingMaskIntoConstraints="NO" id="pTf-KM-cQt">
<rect key="frame" x="16" y="133" width="343" height="43"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" flexibleMinY="YES" heightSizable="YES" flexibleMaxY="YES"/>
<textField opaque="NO" clipsSubviews="YES" contentMode="scaleToFill" contentHorizontalAlignment="left" contentVerticalAlignment="center" placeholder=" 请输入WiFi密码" minimumFontSize="17" clearButtonMode="whileEditing" translatesAutoresizingMaskIntoConstraints="NO" id="pTf-KM-cQt">
<rect key="frame" x="17" y="64" width="343" height="43"/>
<color key="backgroundColor" red="0.94901960784313721" green="0.94901960784313721" blue="0.94901960784313721" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<constraints>
<constraint firstAttribute="height" constant="43" id="zNS-Ou-3gj"/>
</constraints>
<fontDescription key="fontDescription" type="system" pointSize="17"/>
<textInputTraits key="textInputTraits"/>
</textField>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" fixedFrame="YES" text="如果连接有问题,请尝试热点连接模式" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="dwN-It-iak">
<rect key="frame" x="16" y="182" width="217" height="21"/>
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMinY="YES" heightSizable="YES" flexibleMaxY="YES"/>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="如果连接有问题,请尝试热点连接模式" lineBreakMode="tailTruncation" numberOfLines="0" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="dwN-It-iak">
<rect key="frame" x="16" y="136" width="209" height="15"/>
<fontDescription key="fontDescription" type="system" pointSize="12"/>
<color key="textColor" red="0.59999999999999998" green="0.59999999999999998" blue="0.59999999999999998" alpha="1" colorSpace="calibratedRGB"/>
<nil key="highlightedColor"/>
</label>
<button opaque="NO" contentMode="scaleToFill" fixedFrame="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="roundedRect" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="eDA-Ia-DAy">
<rect key="frame" x="225" y="182" width="63" height="21"/>
<autoresizingMask key="autoresizingMask" flexibleMinY="YES" heightSizable="YES" flexibleMaxY="YES"/>
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="roundedRect" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="eDA-Ia-DAy">
<rect key="frame" x="225" y="130" width="50" height="27"/>
<fontDescription key="fontDescription" type="system" pointSize="12"/>
<state key="normal" title="点击这里"/>
<connections>
@ -64,46 +64,59 @@
<rect key="frame" x="16" y="493" width="178" height="154"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" flexibleMaxX="YES" flexibleMinY="YES" heightSizable="YES"/>
</button>
<button opaque="NO" contentMode="scaleToFill" fixedFrame="YES" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="pAw-UG-caT">
<rect key="frame" x="267" y="133" width="92" height="43"/>
<autoresizingMask key="autoresizingMask" flexibleMinX="YES" flexibleMinY="YES" heightSizable="YES" flexibleMaxY="YES"/>
<state key="normal" title="确定" backgroundImage="linkingdevice_botton.png"/>
<connections>
<action selector="makeSureButton:" destination="-1" eventType="touchUpInside" id="MmM-3q-5Lu"/>
</connections>
</button>
<view contentMode="scaleToFill" fixedFrame="YES" translatesAutoresizingMaskIntoConstraints="NO" id="JXU-MG-jdb">
<rect key="frame" x="260" y="133" width="6" height="43"/>
<autoresizingMask key="autoresizingMask" flexibleMinX="YES" flexibleMinY="YES" heightSizable="YES" flexibleMaxY="YES"/>
<color key="backgroundColor" white="1" alpha="1" colorSpace="calibratedWhite"/>
</view>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" fixedFrame="YES" text="ssidLabel" lineBreakMode="tailTruncation" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="dLX-z3-jjZ">
<rect key="frame" x="23" y="79" width="336" height="36"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" flexibleMaxY="YES"/>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="ssidLabel" lineBreakMode="tailTruncation" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="dLX-z3-jjZ">
<rect key="frame" x="24" y="18" width="336" height="36"/>
<constraints>
<constraint firstAttribute="height" constant="36" id="Dw1-TT-raa"/>
</constraints>
<fontDescription key="fontDescription" type="system" pointSize="17"/>
<color key="textColor" red="0.59999999999999998" green="0.59999999999999998" blue="0.59999999999999998" alpha="1" colorSpace="calibratedRGB"/>
<nil key="highlightedColor"/>
</label>
<imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" fixedFrame="YES" image="linkingdevice_point.png" translatesAutoresizingMaskIntoConstraints="NO" id="ZVX-4y-CYu">
<rect key="frame" x="12" y="92" width="10" height="10"/>
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
<imageView userInteractionEnabled="NO" contentMode="scaleToFill" horizontalHuggingPriority="251" verticalHuggingPriority="251" image="linkingdevice_point.png" translatesAutoresizingMaskIntoConstraints="NO" id="ZVX-4y-CYu">
<rect key="frame" x="13" y="31.5" width="9" height="9"/>
</imageView>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="(暂不支持5G网络请使用2.4G网络)" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="Djf-KM-um4">
<rect key="frame" x="23" y="112" width="224" height="16"/>
<constraints>
<constraint firstAttribute="width" constant="224" id="eda-0s-uHB"/>
</constraints>
<fontDescription key="fontDescription" type="system" pointSize="13"/>
<color key="textColor" red="1" green="0.0" blue="0.0" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<nil key="highlightedColor"/>
</label>
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="pAw-UG-caT">
<rect key="frame" x="267" y="64" width="93" height="44"/>
<state key="normal" title="确定" backgroundImage="linkingdevice_botton.png"/>
<connections>
<action selector="makeSureButton:" destination="-1" eventType="touchUpInside" id="MmM-3q-5Lu"/>
</connections>
</button>
</subviews>
<color key="backgroundColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<constraints>
<constraint firstAttribute="trailing" secondItem="dLX-z3-jjZ" secondAttribute="trailing" constant="15" id="4y5-BD-vSU"/>
<constraint firstItem="dwN-It-iak" firstAttribute="leading" secondItem="i5M-Pr-FkT" secondAttribute="leading" constant="16" id="5KQ-lk-Bh2"/>
<constraint firstAttribute="trailing" secondItem="pTf-KM-cQt" secondAttribute="trailing" constant="15" id="9Lh-op-znd"/>
<constraint firstItem="pAw-UG-caT" firstAttribute="top" secondItem="pTf-KM-cQt" secondAttribute="top" id="DIZ-dK-YeC"/>
<constraint firstItem="dLX-z3-jjZ" firstAttribute="leading" secondItem="ZVX-4y-CYu" secondAttribute="trailing" constant="2" id="DiL-E2-Ffv"/>
<constraint firstItem="pAw-UG-caT" firstAttribute="trailing" secondItem="pTf-KM-cQt" secondAttribute="trailing" id="F1u-S4-uOT"/>
<constraint firstItem="eDA-Ia-DAy" firstAttribute="centerY" secondItem="dwN-It-iak" secondAttribute="centerY" id="GhX-wp-8J9"/>
<constraint firstItem="pAw-UG-caT" firstAttribute="leading" secondItem="pTf-KM-cQt" secondAttribute="trailing" constant="-93" id="HbX-QX-BKw"/>
<constraint firstItem="dwN-It-iak" firstAttribute="top" secondItem="Djf-KM-um4" secondAttribute="bottom" constant="8" id="Jo6-Bz-XWs"/>
<constraint firstItem="Djf-KM-um4" firstAttribute="leading" secondItem="i5M-Pr-FkT" secondAttribute="leading" constant="23" id="Om3-mg-wDG"/>
<constraint firstItem="Djf-KM-um4" firstAttribute="top" secondItem="i5M-Pr-FkT" secondAttribute="top" constant="112" id="bPy-nD-6Ia"/>
<constraint firstItem="eDA-Ia-DAy" firstAttribute="leading" secondItem="dwN-It-iak" secondAttribute="trailing" id="UOq-SD-7bv"/>
<constraint firstItem="Djf-KM-um4" firstAttribute="top" secondItem="pTf-KM-cQt" secondAttribute="bottom" constant="5" id="ZI9-XL-QR0"/>
<constraint firstItem="pTf-KM-cQt" firstAttribute="leading" secondItem="i5M-Pr-FkT" secondAttribute="leading" constant="17" id="Zpq-5y-Mzb"/>
<constraint firstItem="ZVX-4y-CYu" firstAttribute="centerY" secondItem="dLX-z3-jjZ" secondAttribute="centerY" id="buo-fh-zXW"/>
<constraint firstItem="dLX-z3-jjZ" firstAttribute="leading" secondItem="i5M-Pr-FkT" secondAttribute="leading" constant="24" id="idB-iY-9tX"/>
<constraint firstItem="pTf-KM-cQt" firstAttribute="top" secondItem="dLX-z3-jjZ" secondAttribute="bottom" constant="10" id="kgi-vi-69m"/>
<constraint firstItem="dLX-z3-jjZ" firstAttribute="top" secondItem="i5M-Pr-FkT" secondAttribute="top" constant="18" id="vxM-7Q-dY3"/>
</constraints>
<point key="canvasLocation" x="-422.5" y="214.5"/>
<nil key="simulatedTopBarMetrics"/>
<point key="canvasLocation" x="-676" y="192.95352323838082"/>
</view>
</objects>
<resources>

View File

@ -13,9 +13,11 @@
@interface ForgetViewController ()
@property (weak, nonatomic) IBOutlet UIButton *timerButton;
@property (weak, nonatomic) IBOutlet UIButton *nextTepBtn;
@property (weak, nonatomic) IBOutlet UIButton *switchBtn;
@property(nonatomic,copy)NSString*verifyData;
@property(nonatomic,copy) NSString *areaCode;
@end
@implementation ForgetViewController
@ -124,11 +126,11 @@
-(void)getVerifycode{
[IFISHHTTPTOOL getverifyWithTimerButton:_timerButton addphoneNumber:self.phoneNumberFiled.text zone:self.areaCode result:^(NSError *err) {
BOOL isTextCode = [[_switchBtn titleForState:UIControlStateNormal] isEqualToString:@"语音验证码"];
[IFISHHTTPTOOL getverifyWithTimerButton:_timerButton addphoneNumber:self.phoneNumberFiled.text zone:self.areaCode isTextCode:isTextCode result:^(NSError *err) {
}];
}
#define mark -
@ -236,4 +238,16 @@
}
#pragma mark -- Actions --
//
- (IBAction)switchAction:(UIButton* )sender {
if ([[self.timerButton titleForState:UIControlStateNormal] isEqualToString:@"语音验证码"]) {
[self.timerButton setTitle:@"短信验证码" forState:UIControlStateNormal];
[sender setTitle:@"语音验证码" forState:UIControlStateNormal];
} else if ([[self.timerButton titleForState:UIControlStateNormal] isEqualToString:@"短信验证码"]) {
[self.timerButton setTitle:@"语音验证码" forState:UIControlStateNormal];
[sender setTitle:@"短信验证码" forState:UIControlStateNormal];
}
}
@end

View File

@ -1,12 +1,11 @@
<?xml version="1.0" encoding="UTF-8"?>
<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="12121" systemVersion="16E195" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" colorMatched="YES">
<device id="retina5_5" orientation="portrait">
<document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="14460.31" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" colorMatched="YES">
<device id="retina4_7" orientation="portrait">
<adaptation id="fullscreen"/>
</device>
<dependencies>
<deployment identifier="iOS"/>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="12089"/>
<capability name="Aspect ratio constraints" minToolsVersion="5.1"/>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="14460.20"/>
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
</dependencies>
<objects>
@ -16,6 +15,7 @@
<outlet property="countryView" destination="Kuc-iA-yGB" id="lJV-d6-vuw"/>
<outlet property="nextTepBtn" destination="ONp-Rz-9VY" id="svf-xf-Go3"/>
<outlet property="phoneNumberFiled" destination="9AU-7X-or2" id="oi7-IL-dVy"/>
<outlet property="switchBtn" destination="PNt-YY-iAQ" id="nnr-9g-i1e"/>
<outlet property="timerButton" destination="qvS-eF-OGr" id="eFS-2p-xwc"/>
<outlet property="verifyTextFiled" destination="m6b-aY-UbD" id="KIH-4Q-u1O"/>
<outlet property="view" destination="i5M-Pr-FkT" id="sfx-zR-JGt"/>
@ -23,14 +23,14 @@
</placeholder>
<placeholder placeholderIdentifier="IBFirstResponder" id="-2" customClass="UIResponder"/>
<view clearsContextBeforeDrawing="NO" contentMode="scaleToFill" id="i5M-Pr-FkT">
<rect key="frame" x="0.0" y="0.0" width="414" height="736"/>
<rect key="frame" x="0.0" y="0.0" width="375" height="667"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews>
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="Fse-85-LUi">
<rect key="frame" x="21" y="93" width="372" height="300.33333333333331"/>
<rect key="frame" x="21" y="93" width="333" height="274"/>
<subviews>
<textField opaque="NO" clipsSubviews="YES" contentMode="scaleToFill" contentHorizontalAlignment="left" contentVerticalAlignment="center" placeholder="请输入您的手机号" textAlignment="natural" minimumFontSize="17" clearButtonMode="whileEditing" translatesAutoresizingMaskIntoConstraints="NO" id="9AU-7X-or2">
<rect key="frame" x="25" y="75.666666666666657" width="322" height="47.666666666666686"/>
<rect key="frame" x="25" y="70" width="283" height="42"/>
<color key="backgroundColor" red="0.94901960780000005" green="0.94901960780000005" blue="0.94901960780000005" alpha="1" colorSpace="calibratedRGB"/>
<constraints>
<constraint firstAttribute="width" secondItem="9AU-7X-or2" secondAttribute="height" multiplier="283:42" id="IW4-cg-TR8"/>
@ -39,7 +39,7 @@
<textInputTraits key="textInputTraits" keyboardType="numberPad"/>
</textField>
<textField opaque="NO" clipsSubviews="YES" contentMode="scaleToFill" contentHorizontalAlignment="left" contentVerticalAlignment="center" placeholder="请输入短信验证码" textAlignment="natural" minimumFontSize="17" clearButtonMode="whileEditing" translatesAutoresizingMaskIntoConstraints="NO" id="m6b-aY-UbD">
<rect key="frame" x="25" y="132.33333333333337" width="322" height="47.666666666666657"/>
<rect key="frame" x="25" y="121" width="283" height="42"/>
<color key="backgroundColor" red="0.94901960780000005" green="0.94901960780000005" blue="0.94901960780000005" alpha="1" colorSpace="calibratedRGB"/>
<constraints>
<constraint firstAttribute="width" secondItem="m6b-aY-UbD" secondAttribute="height" multiplier="283:42" id="FIB-ry-7SG"/>
@ -48,7 +48,7 @@
<textInputTraits key="textInputTraits"/>
</textField>
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="roundedRect" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="ONp-Rz-9VY">
<rect key="frame" x="25" y="208" width="322" height="49"/>
<rect key="frame" x="25" y="191" width="283" height="43"/>
<color key="backgroundColor" red="0.0" green="0.47843137250000001" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<constraints>
<constraint firstAttribute="width" secondItem="ONp-Rz-9VY" secondAttribute="height" multiplier="283:43" id="7QK-kc-iEt"/>
@ -60,21 +60,19 @@
<action selector="nextStep:" destination="-1" eventType="touchUpInside" id="eCT-th-Hqi"/>
</connections>
</button>
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" buttonType="roundedRect" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="qvS-eF-OGr">
<rect key="frame" x="261" y="132.33333333333337" width="86" height="47.666666666666657"/>
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="qvS-eF-OGr">
<rect key="frame" x="222" y="121" width="86" height="42"/>
<color key="backgroundColor" red="0.0" green="0.47843137250000001" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<constraints>
<constraint firstAttribute="width" constant="86" id="p4x-JI-IVe"/>
</constraints>
<fontDescription key="fontDescription" type="system" pointSize="15"/>
<state key="normal" title="语音验证码">
<color key="titleColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
</state>
</button>
<view contentMode="scaleToFill" translatesAutoresizingMaskIntoConstraints="NO" id="Kuc-iA-yGB">
<rect key="frame" x="25" y="20" width="322" height="47.666666666666657"/>
<rect key="frame" x="25" y="20" width="283" height="42"/>
<subviews>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" text="国家/地区" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="4t2-r8-Y7e">
<rect key="frame" x="10" y="13" width="71" height="21"/>
<rect key="frame" x="10" y="10.5" width="71" height="21"/>
<constraints>
<constraint firstAttribute="height" constant="21" id="kBo-mD-Uyr"/>
<constraint firstAttribute="width" constant="71" id="sSK-8u-5YK"/>
@ -84,7 +82,7 @@
<nil key="highlightedColor"/>
</label>
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="right" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="kqZ-N3-UXK">
<rect key="frame" x="102" y="5" width="212" height="39"/>
<rect key="frame" x="63" y="5" width="212" height="33.5"/>
<constraints>
<constraint firstAttribute="width" constant="212" id="mfY-IJ-ZE0"/>
</constraints>
@ -96,7 +94,6 @@
</subviews>
<color key="backgroundColor" red="0.94901960780000005" green="0.94901960780000005" blue="0.94901960780000005" alpha="1" colorSpace="calibratedRGB"/>
<constraints>
<constraint firstItem="kqZ-N3-UXK" firstAttribute="centerY" secondItem="Kuc-iA-yGB" secondAttribute="centerY" id="Epi-7M-LkN"/>
<constraint firstAttribute="width" secondItem="Kuc-iA-yGB" secondAttribute="height" multiplier="283:42" id="Nq1-PQ-s9o"/>
<constraint firstItem="kqZ-N3-UXK" firstAttribute="top" secondItem="Kuc-iA-yGB" secondAttribute="top" constant="5" id="SvQ-gG-zEs"/>
<constraint firstAttribute="trailing" secondItem="kqZ-N3-UXK" secondAttribute="trailing" constant="8" id="ViY-4n-Z5K"/>
@ -105,6 +102,16 @@
<constraint firstItem="4t2-r8-Y7e" firstAttribute="centerY" secondItem="Kuc-iA-yGB" secondAttribute="centerY" id="wUe-7b-dhI"/>
</constraints>
</view>
<button opaque="NO" contentMode="scaleToFill" contentHorizontalAlignment="center" contentVerticalAlignment="center" lineBreakMode="middleTruncation" translatesAutoresizingMaskIntoConstraints="NO" id="PNt-YY-iAQ">
<rect key="frame" x="246" y="241" width="62" height="27"/>
<fontDescription key="fontDescription" type="system" pointSize="12"/>
<state key="normal" title="短信验证码">
<color key="titleColor" white="0.0" alpha="1" colorSpace="custom" customColorSpace="genericGamma22GrayColorSpace"/>
</state>
<connections>
<action selector="switchAction:" destination="-1" eventType="touchUpInside" id="cKh-I5-tup"/>
</connections>
</button>
</subviews>
<color key="backgroundColor" white="1" alpha="1" colorSpace="calibratedWhite"/>
<constraints>
@ -115,10 +122,12 @@
<constraint firstItem="qvS-eF-OGr" firstAttribute="height" secondItem="m6b-aY-UbD" secondAttribute="height" id="7fW-dZ-bcG"/>
<constraint firstAttribute="trailing" secondItem="9AU-7X-or2" secondAttribute="trailing" constant="25" id="BPA-jS-yUj"/>
<constraint firstItem="ONp-Rz-9VY" firstAttribute="top" secondItem="m6b-aY-UbD" secondAttribute="bottom" constant="28" id="C7t-Kf-WQ8"/>
<constraint firstItem="qvS-eF-OGr" firstAttribute="trailing" secondItem="9AU-7X-or2" secondAttribute="trailing" id="ENO-iH-NRW"/>
<constraint firstItem="9AU-7X-or2" firstAttribute="top" secondItem="Kuc-iA-yGB" secondAttribute="bottom" constant="8" id="L1w-J9-O6C"/>
<constraint firstItem="m6b-aY-UbD" firstAttribute="top" secondItem="9AU-7X-or2" secondAttribute="bottom" constant="9" id="LbP-7q-Ho8"/>
<constraint firstItem="qvS-eF-OGr" firstAttribute="leading" secondItem="m6b-aY-UbD" secondAttribute="trailing" constant="-86" id="Lij-Yz-btH"/>
<constraint firstAttribute="trailing" secondItem="Kuc-iA-yGB" secondAttribute="trailing" constant="25" id="MoP-80-S8X"/>
<constraint firstItem="PNt-YY-iAQ" firstAttribute="trailing" secondItem="ONp-Rz-9VY" secondAttribute="trailing" id="ODp-YI-FtE"/>
<constraint firstItem="m6b-aY-UbD" firstAttribute="centerX" secondItem="Fse-85-LUi" secondAttribute="centerX" id="Qur-Jo-Efx"/>
<constraint firstAttribute="trailing" secondItem="ONp-Rz-9VY" secondAttribute="trailing" constant="25" id="dmo-K3-nIC"/>
<constraint firstAttribute="width" secondItem="Fse-85-LUi" secondAttribute="height" multiplier="333:224" constant="-74.33035714285711" id="hja-fF-Y7Q"/>
@ -127,6 +136,7 @@
<constraint firstItem="qvS-eF-OGr" firstAttribute="bottom" secondItem="m6b-aY-UbD" secondAttribute="bottom" id="mHf-AZ-g3T"/>
<constraint firstItem="9AU-7X-or2" firstAttribute="leading" secondItem="Fse-85-LUi" secondAttribute="leading" constant="25" id="mco-Fk-Z4F"/>
<constraint firstItem="Kuc-iA-yGB" firstAttribute="top" secondItem="Fse-85-LUi" secondAttribute="top" constant="20" id="nK2-hI-tfT"/>
<constraint firstItem="PNt-YY-iAQ" firstAttribute="top" secondItem="ONp-Rz-9VY" secondAttribute="bottom" constant="7" id="ona-GE-0ZJ"/>
</constraints>
</view>
</subviews>