From eeb0fad802f9558eb74c6964480b38b49e016c45 Mon Sep 17 00:00:00 2001
From: chenqiyang <1406175257@qq.com>
Date: 星期四, 06 四月 2023 17:40:08 +0800
Subject: [PATCH] 1.增加不能app配网提示页功能 2.修改部分或计划语言
---
EZSDK/EZSDK/EZ/Global/HDLEZConstants.h | 4
EZSDK/EZSDK/EZ/UIViewControllers/EZWifiTipsViewController.m | 2
EZSDK/EZSDK/EZ/UIViewControllers/EZLivePlayViewController.m | 17 +++
EZSDK/EZSDK/EZ/UIViewControllers/EZDeviceResultViewController.m | 171 ++++++++++++++++++++++++++++++++++
EZSDK/EZSDK/EZSDK.h | 2
EZSDK.IOS/EZSDK.IOS/ApiDefinition.cs | 5 +
EZSDK/EZSDK/EZ/UIViewControllers/EZInputSerialViewController.m | 4
EZSDK.IOS/EZSDK.IOS/Resources/hdl_ez_wifi_connect_step_two@3x.png | 0
EZSDK.IOS/EZSDK.IOS/Resources/hdl_ez_wifi_connect_step2@3x.png | 0
EZSDK.IOS/EZSDK.IOS/Resources/hdl_ez_wifi_connect_step1@3x.png | 0
EZSDK/EZSDK/EZ/UIViewControllers/EZAddByQRCodeViewController.m | 1
EZSDK.IOS/EZSDK.IOS/Resources/hdl_ez_wifi_connect_step1@2x.png | 0
EZSDK.IOS/EZSDK.IOS/Resources/hdl_ez_wifi_connect_step_one@3x.png | 0
EZSDK.IOS/EZSDK.IOS/EZSDK.IOS.csproj | 8 +
EZSDK.IOS/EZSDK.IOS/Properties/AssemblyInfo.cs | 2
EZSDK/EZSDK/EZ/UIViewControllers/EZAPWiFiConfigViewController.m | 40 +++++++
EZSDK/EZSDK/EZ/UIViewControllers/EZAPConfigResultViewController.m | 5 +
EZSDK.IOS/EZSDK.IOS/Resources/hdl_ez_wifi_connect_step2@2x.png | 0
EZSDK/EZSDK/EZ/UIViewControllers/EZWifiInfoViewController.m | 21 +++
/dev/null | 0
EZSDK.IOS/EZSDK.IOS/Library/libEZSDK.a | 0
EZSDK/EZSDK/EZ/Global/GlobalKit.m | 2
EZSDK.IOS/EZSDK.IOS/Resources/hdl_ez_wifi_connect_step_one@2x.png | 0
EZSDK.IOS/EZSDK.IOS/Resources/hdl_ez_wifi_connect_step_two@2x.png | 0
EZSDK/EZSDK/EZ/Global/GlobalKit.h | 3
25 files changed, 278 insertions(+), 9 deletions(-)
diff --git a/EZSDK.IOS/EZSDK.IOS/ApiDefinition.cs b/EZSDK.IOS/EZSDK.IOS/ApiDefinition.cs
index d88ddba..2013e15 100644
--- a/EZSDK.IOS/EZSDK.IOS/ApiDefinition.cs
+++ b/EZSDK.IOS/EZSDK.IOS/ApiDefinition.cs
@@ -25,6 +25,11 @@
[NullAllowed, Export("delegate", ArgumentSemantic.Weak)]
NSObject WeakDelegate { get; set; }
+ // @property (nonatomic, strong) NSArray * connectTipModels;
+ [Export("connectTipModels", ArgumentSemantic.Strong)]
+ //[Verify(StronglyTypedNSArray)]
+ NSObject[] ConnectTipModels { get; set; }
+
// +(instancetype)sharedInstance;
[Static]
[Export("sharedInstance")]
diff --git a/EZSDK.IOS/EZSDK.IOS/EZSDK.IOS.csproj b/EZSDK.IOS/EZSDK.IOS/EZSDK.IOS.csproj
index 8a3d1ed..f5ace78 100644
--- a/EZSDK.IOS/EZSDK.IOS/EZSDK.IOS.csproj
+++ b/EZSDK.IOS/EZSDK.IOS/EZSDK.IOS.csproj
@@ -73,6 +73,14 @@
<BundleResource Include="Resources\hdl_ez_temp_pass_word%402x.png" />
<BundleResource Include="Resources\hdl_ez_temp_pass_word%403x.png" />
<BundleResource Include="Resources\hdl_ez_ic_unlock_disable%402x.png" />
+ <BundleResource Include="Resources\hdl_ez_wifi_connect_step_one%402x.png" />
+ <BundleResource Include="Resources\hdl_ez_wifi_connect_step_one%403x.png" />
+ <BundleResource Include="Resources\hdl_ez_wifi_connect_step_two%402x.png" />
+ <BundleResource Include="Resources\hdl_ez_wifi_connect_step_two%403x.png" />
+ <BundleResource Include="Resources\hdl_ez_wifi_connect_step1%402x.png" />
+ <BundleResource Include="Resources\hdl_ez_wifi_connect_step1%403x.png" />
+ <BundleResource Include="Resources\hdl_ez_wifi_connect_step2%402x.png" />
+ <BundleResource Include="Resources\hdl_ez_wifi_connect_step2%403x.png" />
</ItemGroup>
<Import Project="$(MSBuildExtensionsPath)\Xamarin\iOS\Xamarin.iOS.ObjCBinding.CSharp.targets" />
</Project>
\ No newline at end of file
diff --git a/EZSDK.IOS/EZSDK.IOS/Library/libEZSDK.a b/EZSDK.IOS/EZSDK.IOS/Library/libEZSDK.a
index 824db6d..8d7f06d 100644
--- a/EZSDK.IOS/EZSDK.IOS/Library/libEZSDK.a
+++ b/EZSDK.IOS/EZSDK.IOS/Library/libEZSDK.a
Binary files differ
diff --git a/EZSDK.IOS/EZSDK.IOS/Properties/AssemblyInfo.cs b/EZSDK.IOS/EZSDK.IOS/Properties/AssemblyInfo.cs
index 61f72c5..591b381 100644
--- a/EZSDK.IOS/EZSDK.IOS/Properties/AssemblyInfo.cs
+++ b/EZSDK.IOS/EZSDK.IOS/Properties/AssemblyInfo.cs
@@ -25,7 +25,7 @@
// The form "{Major}.{Minor}.*" will automatically update the build and revision,
// and "{Major}.{Minor}.{Build}.*" will update just the revision.
-[assembly: AssemblyVersion("1.5.3")]
+[assembly: AssemblyVersion("1.6.2")]
// The following attributes are used to specify the signing key for the assembly,
// if desired. See the Mono documentation for more information about signing.
diff --git a/EZSDK.IOS/EZSDK.IOS/Resources/hdl_ez_wifi_connect_step1@2x.png b/EZSDK.IOS/EZSDK.IOS/Resources/hdl_ez_wifi_connect_step1@2x.png
new file mode 100644
index 0000000..144400f
--- /dev/null
+++ b/EZSDK.IOS/EZSDK.IOS/Resources/hdl_ez_wifi_connect_step1@2x.png
Binary files differ
diff --git a/EZSDK.IOS/EZSDK.IOS/Resources/hdl_ez_wifi_connect_step1@3x.png b/EZSDK.IOS/EZSDK.IOS/Resources/hdl_ez_wifi_connect_step1@3x.png
new file mode 100644
index 0000000..8b637a0
--- /dev/null
+++ b/EZSDK.IOS/EZSDK.IOS/Resources/hdl_ez_wifi_connect_step1@3x.png
Binary files differ
diff --git a/EZSDK.IOS/EZSDK.IOS/Resources/hdl_ez_wifi_connect_step2@2x.png b/EZSDK.IOS/EZSDK.IOS/Resources/hdl_ez_wifi_connect_step2@2x.png
new file mode 100644
index 0000000..f3e6d66
--- /dev/null
+++ b/EZSDK.IOS/EZSDK.IOS/Resources/hdl_ez_wifi_connect_step2@2x.png
Binary files differ
diff --git a/EZSDK.IOS/EZSDK.IOS/Resources/hdl_ez_wifi_connect_step2@3x.png b/EZSDK.IOS/EZSDK.IOS/Resources/hdl_ez_wifi_connect_step2@3x.png
new file mode 100644
index 0000000..a274b61
--- /dev/null
+++ b/EZSDK.IOS/EZSDK.IOS/Resources/hdl_ez_wifi_connect_step2@3x.png
Binary files differ
diff --git a/EZSDK.IOS/EZSDK.IOS/Resources/hdl_ez_wifi_connect_step_one@2x.png b/EZSDK.IOS/EZSDK.IOS/Resources/hdl_ez_wifi_connect_step_one@2x.png
new file mode 100644
index 0000000..29e36d1
--- /dev/null
+++ b/EZSDK.IOS/EZSDK.IOS/Resources/hdl_ez_wifi_connect_step_one@2x.png
Binary files differ
diff --git a/EZSDK.IOS/EZSDK.IOS/Resources/hdl_ez_wifi_connect_step_one@3x.png b/EZSDK.IOS/EZSDK.IOS/Resources/hdl_ez_wifi_connect_step_one@3x.png
new file mode 100644
index 0000000..bc3a447
--- /dev/null
+++ b/EZSDK.IOS/EZSDK.IOS/Resources/hdl_ez_wifi_connect_step_one@3x.png
Binary files differ
diff --git a/EZSDK.IOS/EZSDK.IOS/Resources/hdl_ez_wifi_connect_step_two@2x.png b/EZSDK.IOS/EZSDK.IOS/Resources/hdl_ez_wifi_connect_step_two@2x.png
new file mode 100644
index 0000000..07a5957
--- /dev/null
+++ b/EZSDK.IOS/EZSDK.IOS/Resources/hdl_ez_wifi_connect_step_two@2x.png
Binary files differ
diff --git a/EZSDK.IOS/EZSDK.IOS/Resources/hdl_ez_wifi_connect_step_two@3x.png b/EZSDK.IOS/EZSDK.IOS/Resources/hdl_ez_wifi_connect_step_two@3x.png
new file mode 100644
index 0000000..a60b4bb
--- /dev/null
+++ b/EZSDK.IOS/EZSDK.IOS/Resources/hdl_ez_wifi_connect_step_two@3x.png
Binary files differ
diff --git a/EZSDK/EZSDK/EZ/Global/GlobalKit.h b/EZSDK/EZSDK/EZ/Global/GlobalKit.h
index ee0fc5e..22e13c7 100644
--- a/EZSDK/EZSDK/EZ/Global/GlobalKit.h
+++ b/EZSDK/EZSDK/EZ/Global/GlobalKit.h
@@ -33,6 +33,9 @@
@property (nonatomic, copy) NSString *configDevSerial; //鎸囧畾璁惧搴忓垪鍙凤紙鍙�夛級
@property (nonatomic, assign) HDLEZDeviceType deviceType;//璁惧绫诲瀷
+@property (nonatomic, copy) NSString *WiFiConfigPrefix;//閰嶇綉鐨勫墠缂�锛氳悿鐭虫槸EZVIZ
+
+
+ (instancetype)shareKit;
- (void)clearSession;
diff --git a/EZSDK/EZSDK/EZ/Global/GlobalKit.m b/EZSDK/EZSDK/EZ/Global/GlobalKit.m
index c58d0ad..4e27ab3 100644
--- a/EZSDK/EZSDK/EZ/Global/GlobalKit.m
+++ b/EZSDK/EZSDK/EZ/Global/GlobalKit.m
@@ -35,6 +35,8 @@
_hdlRefreshToken = [[NSUserDefaults standardUserDefaults] objectForKey:EZhdlRefreshToken];
_deviceVerifyCodeBySerial = [NSMutableDictionary new];
+
+ self.WiFiConfigPrefix = @"EZVIZ";
}
return self;
}
diff --git a/EZSDK/EZSDK/EZ/Global/HDLEZConstants.h b/EZSDK/EZSDK/EZ/Global/HDLEZConstants.h
index 99140dd..9ab6308 100755
--- a/EZSDK/EZSDK/EZ/Global/HDLEZConstants.h
+++ b/EZSDK/EZSDK/EZ/Global/HDLEZConstants.h
@@ -44,8 +44,8 @@
// Design Width&Height
#define HDLEZDesignWidth 375
#define HDLEZDesignHeight 667
-#define HDLEZGetRealWidth(W) W / (HDLEZDesignWidth * 1.0f / APP_SCREEN_WIDTH)
-#define HDLEZGetRealHeight(H) H / (HDLEZDesignHeight * 1.0f / APP_SCREEN_HEIGHT)
+#define HDLEZGetRealWidth(W) W / (HDLEZDesignWidth * 1.0f / HDLEZ_APP_SCREEN_WIDTH)
+#define HDLEZGetRealHeight(H) H / (HDLEZDesignHeight * 1.0f / HDLEZ_APP_SCREEN_HEIGHT)
// 瀛椾綋棰滆壊*
diff --git a/EZSDK/EZSDK/EZ/UIViewControllers/EZAPConfigResultViewController.m b/EZSDK/EZSDK/EZ/UIViewControllers/EZAPConfigResultViewController.m
index 98abe9e..fa4f1e7 100644
--- a/EZSDK/EZSDK/EZ/UIViewControllers/EZAPConfigResultViewController.m
+++ b/EZSDK/EZSDK/EZ/UIViewControllers/EZAPConfigResultViewController.m
@@ -70,6 +70,10 @@
[self.view addSubview:self.verifiedBtn];
[self.verifiedBtn setHidden:YES];
+ //鍥介檯鍖栬瑷�
+ [self.doneBtn setTitle:HDLEZLocallizedString(@"complete") forState:UIControlStateNormal];
+ [self.retryBtn setTitle:HDLEZLocallizedString(@"retry") forState:UIControlStateNormal];
+ self.msgLabel.text=HDLEZLocallizedString(@"ad_adding_msg");
}
#pragma mark - actions
@@ -184,6 +188,7 @@
}
else
{
+ [self stopTimer];
// [EZOpenSDK addDevice:[GlobalKit shareKit].deviceSerialNo
// verifyCode:[GlobalKit shareKit].deviceVerifyCode
// completion:^(NSError *error) {
diff --git a/EZSDK/EZSDK/EZ/UIViewControllers/EZAPWiFiConfigViewController.m b/EZSDK/EZSDK/EZ/UIViewControllers/EZAPWiFiConfigViewController.m
index 37e9a63..0dd3e3d 100644
--- a/EZSDK/EZSDK/EZ/UIViewControllers/EZAPWiFiConfigViewController.m
+++ b/EZSDK/EZSDK/EZ/UIViewControllers/EZAPWiFiConfigViewController.m
@@ -23,6 +23,14 @@
@property (weak, nonatomic) IBOutlet UILabel *stepTwoLabel;
@property (weak, nonatomic) IBOutlet UIActivityIndicatorView *processingIndicator;
@property (weak, nonatomic) IBOutlet UIButton *addBtn;
+@property (unsafe_unretained, nonatomic) IBOutlet UILabel *stepThreeLable;
+@property (unsafe_unretained, nonatomic) IBOutlet UILabel *tipLable;
+@property (unsafe_unretained, nonatomic) IBOutlet UILabel *step1TipLable;
+@property (unsafe_unretained, nonatomic) IBOutlet UILabel *passwordLable;
+@property (unsafe_unretained, nonatomic) IBOutlet UILabel *nameL;
+
+@property (unsafe_unretained, nonatomic) IBOutlet UIButton *toCopBtn;
+@property (unsafe_unretained, nonatomic) IBOutlet UIButton *toSetBtn;
@property (nonatomic,copy) NSString *devicWifiName;
@property (nonatomic,strong) NSTimer *timer;
@@ -61,9 +69,12 @@
- (void) initSubviews
{
self.processingIndicator.hidden = YES;
- self.devicWifiName = [NSString stringWithFormat:@"EZVIZ_%@",[GlobalKit shareKit].deviceSerialNo];
+
+// self.devicWifiName = [NSString stringWithFormat:@"EZVIZ_%@",[GlobalKit shareKit].deviceSerialNo];
+ self.devicWifiName = [NSString stringWithFormat:@"%@_%@",[GlobalKit shareKit].WiFiConfigPrefix,[GlobalKit shareKit].deviceSerialNo];
self.wifiNameLabel.text = self.devicWifiName;
- self.wifiPwdLabel.text = [NSString stringWithFormat:@"EZVIZ_%@",[GlobalKit shareKit].deviceVerifyCode];
+// self.wifiPwdLabel.text = [NSString stringWithFormat:@"EZVIZ_%@",[GlobalKit shareKit].deviceVerifyCode];
+ self.wifiPwdLabel.text = [NSString stringWithFormat:@"%@_%@",[GlobalKit shareKit].WiFiConfigPrefix,[GlobalKit shareKit].deviceVerifyCode];
NSString *str = [NSString stringWithFormat:NSLocalizedString(@"wifi_step_two_msg",@"杩涘叆鎵嬫満绯荤粺Wi-Fi璁剧疆鐣岄潰锛岄�夋嫨鍚嶇О涓�%@鐨勭綉缁滐紝鐢ㄦ彁绀虹殑瀵嗙爜杩涜杩炴帴"),self.devicWifiName];
NSMutableAttributedString *aStr = [[NSMutableAttributedString alloc] initWithString:str];
@@ -78,6 +89,31 @@
[aStr addAttribute:NSParagraphStyleAttributeName value:paragraphStyle range:NSMakeRange(0, [aStr length])];
self.stepTwoLabel.attributedText = aStr;
+
+ //绗笁姝�
+ NSString *stepThreeStr=HDLEZLocallizedString(@"wifi_config_step_three");
+ NSString *tipStr=HDLEZLocallizedString(@"wifi_config_step_three_tip");
+ NSString *step3FinalStr=[NSString stringWithFormat:@"%@ %@",stepThreeStr,tipStr];
+ NSMutableAttributedString *aTipStr = [[NSMutableAttributedString alloc] initWithString:[NSString stringWithFormat:@"%@ %@",stepThreeStr,tipStr]];
+ //鍏抽敭瀛楃棰滆壊璋冩暣
+ [aTipStr addAttribute:NSForegroundColorAttributeName
+ value:[UIColor redColor]
+ range:[step3FinalStr rangeOfString:tipStr]];
+ self.stepThreeLable.attributedText = aTipStr;
+ self.stepThreeLable.adjustsFontSizeToFitWidth=YES;
+
+
+ //璁剧疆鍥介檯鍖栬瑷�
+ self.tipLable.text=HDLEZLocallizedString(@"wifi_config_tip");
+ self.tipLable.adjustsFontSizeToFitWidth=YES;
+ self.step1TipLable.text=HDLEZLocallizedString(@"wifi_config_step_1_tips");
+ self.nameL.text=HDLEZLocallizedString(@"wifi_config_name");
+ self.passwordLable.text=HDLEZLocallizedString(@"wifi_config_step_2_password");
+ [self.toCopBtn setTitle:HDLEZLocallizedString(@"wifi_config_copy_pwd") forState:UIControlStateNormal];
+ [self.toSetBtn setTitle:HDLEZLocallizedString(@"wifi_config_to_setting") forState:UIControlStateNormal];
+ [self.addBtn setTitle:HDLEZLocallizedString(@"wifi_ap_add_device_title") forState:UIControlStateNormal];
+
+
}
-(void) startAction
diff --git a/EZSDK/EZSDK/EZ/UIViewControllers/EZAddByQRCodeViewController.m b/EZSDK/EZSDK/EZ/UIViewControllers/EZAddByQRCodeViewController.m
index b1592e9..1648a23 100644
--- a/EZSDK/EZSDK/EZ/UIViewControllers/EZAddByQRCodeViewController.m
+++ b/EZSDK/EZSDK/EZ/UIViewControllers/EZAddByQRCodeViewController.m
@@ -71,6 +71,7 @@
HDLEZLog(@"瀵艰埅鏍忓瓙view锛�%@",self.prevController );
+ self.tipsLabel.text=HDLEZLocallizedString(@"device_add_device_qr_code");
}
- (void)viewWillAppear:(BOOL)animated
diff --git a/EZSDK/EZSDK/EZ/UIViewControllers/EZDeviceResultViewController.m b/EZSDK/EZSDK/EZ/UIViewControllers/EZDeviceResultViewController.m
index 90b5895..a3ebc31 100644
--- a/EZSDK/EZSDK/EZ/UIViewControllers/EZDeviceResultViewController.m
+++ b/EZSDK/EZSDK/EZ/UIViewControllers/EZDeviceResultViewController.m
@@ -29,6 +29,21 @@
@property (nonatomic,assign) BOOL supportApMode;
@property (nonatomic,assign) BOOL supportSmartMode;
@property (nonatomic,assign) BOOL supportSoundMode;
+
+@property (nonatomic,strong) UIView *tipView ;//閰嶇綉鎻愮ずview
+
+@property (nonatomic,strong) UIImageView *step1TipImgV ;//姝ラ1鎻愮ず鍥緑iew
+@property (nonatomic,strong) UIImageView *step1ImgV ;//姝ラ1鍥緑iew
+@property (nonatomic,strong) UILabel *step1DescribeL ;//姝ラ1鎻忚堪lable
+
+@property (nonatomic,strong) UIImageView *step2TipImgV ;//姝ラ2鎻愮ず鍥緑iew
+@property (nonatomic,strong) UIImageView *step2ImgV ;//姝ラ2鍥緑iew
+@property (nonatomic,strong) UILabel *step2DescribeL ;//姝ラ2鎻忚堪lable
+
+
+@property (nonatomic,strong) UIView *btnBackView ;//鎸夐挳鑳屾櫙view
+@property (nonatomic,strong) UIButton *connectedBtn;//宸茶繛鎺ユ寜閽�
+
@end
@implementation EZDeviceResultViewController
@@ -223,6 +238,10 @@
error.code == EZ_HTTPS_DEVICE_NOT_EXISTS ||
error.code == EZ_HTTPS_DEVICE_OFFLINE_IS_ADDED_MYSELF)
{
+ if ([[EZSDK sharedInstance].connectTipModels containsObject:deviceInfo.model]||[self checkIfShouldTipWithDeviceModel:deviceInfo.model]) {//涓洪渶瑕佹彁绀洪厤缃戠殑绫诲瀷
+ [self showConnectWifiTipView];
+ return;
+ }
self.statusLabel.hidden = NO;
self.actionButton.hidden = NO;
if (deviceInfo)
@@ -238,6 +257,9 @@
self.supportSmartMode = YES;
self.supportSoundMode = YES;
}
+
+ self.statusLabel.text =HDLEZLocallizedString(@"wifi_config_not_connected");
+
[self.actionButton setTitle:NSLocalizedString(@"ad_connect_net", @"杩炴帴缃戠粶") forState:UIControlStateNormal];
}
else
@@ -261,6 +283,155 @@
}
+/*妫�娴媘odel鏄惁鍖呭惈闇�瑕佹彁绀虹殑绫诲瀷
+ */
+-(BOOL)checkIfShouldTipWithDeviceModel:(NSString*)deviceModel{
+ for (NSString *model in [EZSDK sharedInstance].connectTipModels) {
+ if ([deviceModel containsString:[NSString stringWithFormat:@"-%@-",model]]) {
+ return YES;
+ break;
+ }
+ }
+ return NO;
+}
+
+/*鎻愮ずview
+ */
+-(UIView*)tipView{
+ if (!_tipView) {
+ //鎻愮ずview
+ _tipView=[[UIView alloc] init];
+ [self.view addSubview:_tipView];
+ [_tipView mas_makeConstraints:^(MASConstraintMaker *make) {
+ make.top.equalTo(self.view).offset(HDLEZ_APP_TOP_BAR_HEIGHT);
+ make.left.bottom.right.equalTo(self.view);
+ }];
+ _tipView.backgroundColor=HDLEZ_COLOR_VIEW_BACKGROUND;
+
+ //姝ラ1鎸囩ず鍥�
+ _step1TipImgV=[[UIImageView alloc] init];
+ [_tipView addSubview:_step1TipImgV];
+ [_step1TipImgV mas_makeConstraints:^(MASConstraintMaker *make) {
+ make.top.equalTo(_tipView).offset(33);
+ make.left.equalTo(_tipView).offset(HDLEZGetRealWidth(33));
+ make.width.mas_equalTo(130);
+ make.height.mas_equalTo(120);
+ }];
+ _step1TipImgV.image=[UIImage imageNamed:@"hdl_ez_wifi_connect_step1"];
+
+ //姝ラ1鍥�
+ _step1ImgV=[[UIImageView alloc] init];
+ [_tipView addSubview:_step1ImgV];
+ [_step1ImgV mas_makeConstraints:^(MASConstraintMaker *make) {
+ make.top.equalTo(_step1TipImgV.mas_bottom).offset(13);
+ make.left.equalTo(_step1TipImgV).offset(7);
+ make.width.mas_equalTo(19);
+ make.height.mas_equalTo(22);
+ }];
+ _step1ImgV.image=[UIImage imageNamed:@"hdl_ez_wifi_connect_step_one"];
+
+ //姝ラ1鎻忚堪lable
+ _step1DescribeL=[[UILabel alloc] init];
+ [_tipView addSubview:_step1DescribeL];
+ [_step1DescribeL mas_makeConstraints:^(MASConstraintMaker *make) {
+ make.top.equalTo(_step1ImgV.mas_bottom).offset(7);
+ make.left.equalTo(_step1ImgV);
+ make.right.equalTo(_step1TipImgV);
+ make.height.mas_equalTo(22);
+ }];
+ _step1DescribeL.font=HDLEZ_Get_FontBoldWithSize(HDLEZ_FontSize_16);
+ _step1DescribeL.textColor=HDLEZ_COLOR_TEXT_TITLE_GRAY;
+ _step1DescribeL.numberOfLines=2;
+ _step1DescribeL.adjustsFontSizeToFitWidth=YES;
+ _step1DescribeL.text=HDLEZLocallizedString(@"wifi_config_select_set_param");
+
+ //姝ラ2鎸囩ず鍥�
+ _step2TipImgV=[[UIImageView alloc] init];
+ [_tipView addSubview:_step2TipImgV];
+ [_step2TipImgV mas_makeConstraints:^(MASConstraintMaker *make) {
+ make.top.equalTo(_tipView).offset(33);
+ make.right.equalTo(_tipView).offset(HDLEZGetRealWidth(-33));
+ make.width.mas_equalTo(130);
+ make.height.mas_equalTo(120);
+ }];
+ _step2TipImgV.image=[UIImage imageNamed:@"hdl_ez_wifi_connect_step2"];
+
+ //姝ラ2鍥�
+ _step2ImgV=[[UIImageView alloc] init];
+ [_tipView addSubview:_step2ImgV];
+ [_step2ImgV mas_makeConstraints:^(MASConstraintMaker *make) {
+ make.top.equalTo(_step2TipImgV.mas_bottom).offset(13);
+ make.left.equalTo(_step2TipImgV).offset(7);
+ make.width.mas_equalTo(19);
+ make.height.mas_equalTo(22);
+ }];
+ _step2ImgV.image=[UIImage imageNamed:@"hdl_ez_wifi_connect_step_two"];
+
+ //姝ラ2鎻忚堪lable
+ _step2DescribeL=[[UILabel alloc] init];
+ [_tipView addSubview:_step2DescribeL];
+ [_step2DescribeL mas_makeConstraints:^(MASConstraintMaker *make) {
+ make.top.equalTo(_step2ImgV.mas_bottom).offset(7);
+ make.left.equalTo(_step2ImgV);
+ make.right.equalTo(_step2TipImgV);
+ make.height.mas_equalTo(22);
+ }];
+ _step2DescribeL.font=HDLEZ_Get_FontBoldWithSize(HDLEZ_FontSize_16);
+ _step2DescribeL.textColor=HDLEZ_COLOR_TEXT_TITLE_GRAY;
+ _step2DescribeL.numberOfLines=2;
+ _step2DescribeL.adjustsFontSizeToFitWidth=YES;
+ _step2DescribeL.text=HDLEZLocallizedString(@"wifi_config_select_wifi");
+
+ //宸茶繛鎺ユ寜閽儗鏅痸iew
+ _btnBackView=[[UIView alloc] init];
+ [_tipView addSubview:_btnBackView];
+ [_btnBackView mas_makeConstraints:^(MASConstraintMaker *make) {
+ make.left.bottom.right.equalTo(_tipView);
+ make.height.mas_equalTo(76);
+ }];
+ _btnBackView.backgroundColor=HDLEZ_COLOR_VIEW_FOREGROUND;
+ _btnBackView.layer.cornerRadius = 16;
+ _btnBackView.layer.maskedCorners = kCALayerMinXMinYCorner | kCALayerMaxXMinYCorner;
+
+
+ //宸茶繛鎺ユ寜閽�
+ _connectedBtn=[[UIButton alloc] init];
+ [_btnBackView addSubview:_connectedBtn];
+ [_connectedBtn mas_makeConstraints:^(MASConstraintMaker *make) {
+ make.left.equalTo(_tipView).offset(78);
+ make.right.equalTo(_tipView).offset(-78);
+ make.top.equalTo(_btnBackView).offset(12);
+ make.height.mas_equalTo(44);
+ }];
+ _connectedBtn.layer.cornerRadius = 22;
+ [_connectedBtn setBackgroundColor:HDLEZ_COLOR_BACKGROUND_BUTTON];
+ [_connectedBtn setTitle:HDLEZLocallizedString(@"wifi_config_connected") forState:UIControlStateNormal];
+ _connectedBtn.titleLabel.font=HDLEZ_Get_FontBoldWithSize(HDLEZ_FontSize_16);
+ [_connectedBtn setTitleColor:HDLEZ_COLOR_TEXT_WHITE forState:UIControlStateNormal];
+ [_connectedBtn addTarget:self action:@selector(Connected) forControlEvents:UIControlEventTouchUpInside];
+ }
+ return _tipView;
+}
+
+/*灞曠ず寮曞view锛堣悿鐭抽儴鍒嗚澶囦笉鑳介�氳繃璇ユ祦绋嬭繘琛岄厤缃戯級
+ */
+-(void)showConnectWifiTipView{
+ self.title = HDLEZLocallizedString(@"wifi_config_net_work");
+ [self.tipView setHidden:NO];
+
+}
+
+/*宸茶繛鎺�
+ */
+-(void)Connected{
+ self.title = HDLEZLocallizedString(@"ad_result_title");
+
+ //闅愯棌鎸囩ずview
+ [self.tipView setHidden:YES];
+
+ [self doSearchDevice];
+}
+
- (void)handleTheError:(ResponseData *)responseData
{
if (responseData.success)
diff --git a/EZSDK/EZSDK/EZ/UIViewControllers/EZInputSerialViewController.m b/EZSDK/EZSDK/EZ/UIViewControllers/EZInputSerialViewController.m
index 41ba5dc..cfb7378 100644
--- a/EZSDK/EZSDK/EZ/UIViewControllers/EZInputSerialViewController.m
+++ b/EZSDK/EZSDK/EZ/UIViewControllers/EZInputSerialViewController.m
@@ -36,6 +36,10 @@
self.verifyCodeTextField.leftView = [[UIView alloc] initWithFrame:CGRectMake(0, 0, 10, 30)];
self.verifyCodeTextField.leftViewMode = UITextFieldViewModeAlways;
[self.verifyCodeTextField dd_addSeparatorWithType:ViewSeparatorTypeVerticalSide];
+
+ self.serialTextField.placeholder=HDLEZLocallizedString(@"wifi_config_seria_num");
+ self.verifyCodeTextField.placeholder=HDLEZLocallizedString(@"wifi_config_verify_code");
+ [self.nextButton setTitle:HDLEZLocallizedString(@"wifi_config_step_2_next_step") forState:UIControlStateNormal];
}
- (void)didReceiveMemoryWarning {
diff --git a/EZSDK/EZSDK/EZ/UIViewControllers/EZLivePlayViewController.m b/EZSDK/EZSDK/EZ/UIViewControllers/EZLivePlayViewController.m
index 14f7798..2167f96 100644
--- a/EZSDK/EZSDK/EZ/UIViewControllers/EZLivePlayViewController.m
+++ b/EZSDK/EZSDK/EZ/UIViewControllers/EZLivePlayViewController.m
@@ -581,6 +581,23 @@
}
+///**
+// * 鏀跺埌鐨勭敾闈㈤暱瀹藉��
+// *
+// * @param player 鎾斁鍣ㄥ璞�
+// * @param height 楂樺害
+// * @param width 瀹藉害
+// */
+//- (void)player:(EZPlayer *)player didReceivedDisplayHeight:(NSInteger)height displayWidth:(NSInteger)width{
+// HDLEZLog(@"鐢婚潰闀匡細%ld锛屽锛�%ld",(long)height,(long)width);
+// CGFloat playerVH=self.playerView.frame.size.height;
+// CGFloat playerVW=playerVH*(width/height);
+// self.playerView.frame=CGRectMake(0, 0, 50, 50);
+// HDLEZLog(@"playerView鐨刦rame锛�%f",self.playerView.frame.size.width);
+//
+//}
+
+
- (void)player:(EZPlayer *)player didPlayFailed:(NSError *)error
{
NSLog(@"player: %@, didPlayFailed: %@", player, error);
diff --git a/EZSDK/EZSDK/EZ/UIViewControllers/EZWifiInfoViewController.m b/EZSDK/EZSDK/EZ/UIViewControllers/EZWifiInfoViewController.m
index 101a4d0..9ee20c1 100644
--- a/EZSDK/EZSDK/EZ/UIViewControllers/EZWifiInfoViewController.m
+++ b/EZSDK/EZSDK/EZ/UIViewControllers/EZWifiInfoViewController.m
@@ -11,6 +11,7 @@
#import "DDKit.h"
#import "EZWifiConfigViewController.h"
#import "EZAPWiFiConfigViewController.h"
+#import "GlobalKit.h"
#define WIFI_PREFROOT_URL @"prefs:root=WIFI"
#define WIFI_IOS10_WIFI_URL @"App-Prefs:root=WIFI"
@@ -49,6 +50,15 @@
[self.nameTextField dd_addCornerRadius:4.0f lineColor:[UIColor lightGrayColor]];
[self.passwordTextField dd_addCornerRadius:4.0f lineColor:[UIColor lightGrayColor]];
[self.nextButton dd_addCornerRadius:19.0 lineColor:[UIColor dd_hexStringToColor:@"0x1b9ee2"]];
+
+ self.tipsLabel.text=HDLEZLocallizedString(@"wifi_config_step_2_tips");
+ self.tipsLabel.adjustsFontSizeToFitWidth=YES;
+
+ [self.nextButton setTitle:HDLEZLocallizedString(@"wifi_config_step_2_next_step") forState:UIControlStateNormal];
+
+ self.nameLabel.text=HDLEZLocallizedString(@"wifi_config_step_2_net");
+ self.passwordLabel.text=HDLEZLocallizedString(@"wifi_config_step_2_password");
+
}
- (void) viewWillAppear:(BOOL)animated
@@ -94,6 +104,7 @@
for (NSString *ifnam in interfaces)
{
NSDictionary *info = CFBridgingRelease(CNCopyCurrentNetworkInfo((__bridge CFStringRef)ifnam));
+ HDLEZLog(@"info锛�%@",info);
self.nameTextField.text = info[@"SSID"];
break;
}
@@ -230,10 +241,14 @@
- (IBAction)nextAction:(id)sender
{
- //鐑偣閰嶇綉
- [self performSegueWithIdentifier:@"go2APWifiConfig" sender:nil];
+ if ([GlobalKit shareKit].deviceType==HDLEZDeviceType_Door) {//涓洪棬閿�
+ //鐑偣閰嶇綉
+ [self performSegueWithIdentifier:@"go2APWifiConfig" sender:nil];
+ }else{
+ [self showModeSelect];
+ }
-// [self showModeSelect];
+
}
@end
diff --git a/EZSDK/EZSDK/EZ/UIViewControllers/EZWifiTipsViewController.m b/EZSDK/EZSDK/EZ/UIViewControllers/EZWifiTipsViewController.m
index e34b024..90b097b 100644
--- a/EZSDK/EZSDK/EZ/UIViewControllers/EZWifiTipsViewController.m
+++ b/EZSDK/EZSDK/EZ/UIViewControllers/EZWifiTipsViewController.m
@@ -134,7 +134,7 @@
if ([CLLocationManager authorizationStatus] == kCLAuthorizationStatusDenied
|| [CLLocationManager authorizationStatus] == kCLAuthorizationStatusRestricted
|| [CLLocationManager authorizationStatus] == kCLAuthorizationStatusNotDetermined) {
-
+
[self pushToLocationAlertVC];
}
else {
diff --git a/EZSDK/EZSDK/EZSDK.h b/EZSDK/EZSDK/EZSDK.h
index 76dbc29..3532d07 100644
--- a/EZSDK/EZSDK/EZSDK.h
+++ b/EZSDK/EZSDK/EZSDK.h
@@ -24,6 +24,8 @@
@property (nonatomic, weak) id<EZSDKDelegate> delegate;//浠g悊
+@property (nonatomic, strong) NSArray *connectTipModels;//闇�瑕侀厤缃戞彁绀虹殑绫诲瀷锛堜笉鑳介�氳繃app绔厤缃戠殑璁惧绫诲瀷锛�
+
///sharedInstance
+ (instancetype)sharedInstance;
diff --git a/EZSDK/EZSDK/SDK/libEZOpenSDK.a b/EZSDK/EZSDK/SDK/libEZOpenSDK.a
deleted file mode 100644
index 6495b73..0000000
--- a/EZSDK/EZSDK/SDK/libEZOpenSDK.a
+++ /dev/null
Binary files differ
--
Gitblit v1.8.0