|
@@ -22,6 +22,7 @@
|
|
|
#import "customLaunchView.h"
|
|
|
#import "RSATool.h"
|
|
|
#import "forgetPwdViewController.h"
|
|
|
+#import "TipsQRCodeForChangeDeviceViewController.h"
|
|
|
|
|
|
@interface SceneDelegate ()<SetUsePWDViewControllerDelegate,GuideViewControllerDelegate>
|
|
|
@property(nonatomic, strong) CalculatorViewController *calculatorVC;
|
|
@@ -56,6 +57,10 @@
|
|
|
|
|
|
[[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(forgetPwdDidSetPwdFun:) name:forgetPwdDidSetNotification object:nil];
|
|
|
|
|
|
+ [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(scanChangeDeviceFun:) name:scanChangeDeviceNotification object:nil];
|
|
|
+
|
|
|
+ [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(scanChangeDeviceBackFun:) name:scanChangeDeviceBackNotification object:nil];
|
|
|
+
|
|
|
UIWindowScene *windowScene = (UIWindowScene *)scene;
|
|
|
self.window = [[UIWindow alloc] initWithWindowScene:windowScene];
|
|
|
self.window.frame = CGRectMake(0, 0, [UIScreen mainScreen].bounds.size.width, [UIScreen mainScreen].bounds.size.height);
|
|
@@ -192,6 +197,7 @@
|
|
|
|
|
|
if(_curPlayerVC){
|
|
|
[_curPlayerVC disconnectVideoServer];
|
|
|
+ _curPlayerVC = nil;
|
|
|
}
|
|
|
|
|
|
//每次进入
|
|
@@ -625,9 +631,6 @@
|
|
|
- (void)forgetPwdFun:(NSNotification*)not
|
|
|
{
|
|
|
|
|
|
- [_curPlayerVC disconnectVideoServer];
|
|
|
- _preRootPlayerNav = nil;
|
|
|
-
|
|
|
/*忘记密码*/
|
|
|
forgetPwdViewController *forgetPwdVC = [[forgetPwdViewController alloc] init];
|
|
|
BaseNavigationController *forgetPwdVCNav = [[BaseNavigationController alloc] initWithRootViewController:forgetPwdVC];
|
|
@@ -665,4 +668,30 @@
|
|
|
[connectDeviceManager shareInstance].isFirstInputPwdDone = YES;
|
|
|
}
|
|
|
|
|
|
+
|
|
|
+#pragma mark 扫码切换设备 scanChangeDeviceNotification
|
|
|
+- (void)scanChangeDeviceFun:(NSNotification*)not
|
|
|
+{
|
|
|
+
|
|
|
+ TipsQRCodeForChangeDeviceViewController *nextVC = [[TipsQRCodeForChangeDeviceViewController alloc] init];
|
|
|
+ nextVC.isRootVCType = YES;
|
|
|
+ BaseNavigationController *nextNav = [[BaseNavigationController alloc] initWithRootViewController:nextVC];
|
|
|
+ self.window.rootViewController = nextNav;
|
|
|
+
|
|
|
+}
|
|
|
+
|
|
|
+#pragma mark 扫码切换设备点击返回
|
|
|
+- (void)scanChangeDeviceBackFun:(NSNotification*)not
|
|
|
+{
|
|
|
+ if(_preRootPlayerNav)
|
|
|
+ {
|
|
|
+ self.window.rootViewController = _preRootPlayerNav;
|
|
|
+ }
|
|
|
+ else{
|
|
|
+ [self enterMainVCFromScene];
|
|
|
+ }
|
|
|
+
|
|
|
+ [self showCalculatorVC];
|
|
|
+}
|
|
|
+
|
|
|
@end
|