| Index: remoting/ios/app/app_delegate.mm
|
| diff --git a/remoting/ios/app/app_delegate.mm b/remoting/ios/app/app_delegate.mm
|
| index 50a7597cc81d116f771850da072ba007c50ce668..9a9abec72f1db60d50aad1e96c9e4b6f8000be5f 100644
|
| --- a/remoting/ios/app/app_delegate.mm
|
| +++ b/remoting/ios/app/app_delegate.mm
|
| @@ -14,8 +14,7 @@
|
|
|
| #import "remoting/ios/app/app_view_controller.h"
|
| #import "remoting/ios/app/remoting_view_controller.h"
|
| -#import "remoting/ios/facade/remoting_authentication.h"
|
| -#import "remoting/ios/facade/remoting_service.h"
|
| +#import "remoting/ios/facade/remoting_oauth_authentication.h"
|
|
|
| @interface AppDelegate () {
|
| AppViewController* _appViewController;
|
| @@ -40,7 +39,11 @@
|
| return YES;
|
| }
|
|
|
| +#ifndef NDEBUG
|
| - (BOOL)application:(UIApplication*)application handleOpenURL:(NSURL*)url {
|
| + DCHECK([RemotingService.instance.authentication
|
| + isKindOfClass:[RemotingOAuthAuthentication class]]);
|
| +
|
| NSMutableDictionary* components = [[NSMutableDictionary alloc] init];
|
| NSArray* urlComponents = [[url query] componentsSeparatedByString:@"&"];
|
|
|
| @@ -52,12 +55,13 @@
|
| }
|
| NSString* authorizationCode = [components objectForKey:@"code"];
|
|
|
| - [[RemotingService SharedInstance].authentication
|
| + [(RemotingOAuthAuthentication*)RemotingService.instance.authentication
|
| authenticateWithAuthorizationCode:authorizationCode];
|
|
|
| [self launchRemotingViewController];
|
| return YES;
|
| }
|
| +#endif // ifndef NDEBUG
|
|
|
| #pragma mark - Public
|
| - (void)showMenuAnimated:(BOOL)animated {
|
| @@ -88,7 +92,6 @@
|
| UINavigationController* navController =
|
| [[UINavigationController alloc] initWithRootViewController:vc];
|
| navController.navigationBarHidden = true;
|
| -
|
| _appViewController =
|
| [[AppViewController alloc] initWithMainViewController:navController];
|
| self.window.rootViewController = _appViewController;
|
|
|