| Index: remoting/ios/app/app_delegate.mm
|
| diff --git a/remoting/ios/app/app_delegate.mm b/remoting/ios/app/app_delegate.mm
|
| index d6c87e00505ca54eb8cfa034a36f6a4a2349a20f..50a7597cc81d116f771850da072ba007c50ce668 100644
|
| --- a/remoting/ios/app/app_delegate.mm
|
| +++ b/remoting/ios/app/app_delegate.mm
|
| @@ -12,10 +12,16 @@
|
| #include "ui/base/l10n/l10n_util.h"
|
| #include "ui/base/resource/resource_bundle.h"
|
|
|
| +#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"
|
|
|
| +@interface AppDelegate () {
|
| + AppViewController* _appViewController;
|
| +}
|
| +@end
|
| +
|
| @implementation AppDelegate
|
|
|
| @synthesize window = _window;
|
| @@ -53,12 +59,39 @@
|
| return YES;
|
| }
|
|
|
| +#pragma mark - Public
|
| +- (void)showMenuAnimated:(BOOL)animated {
|
| + DCHECK(_appViewController != nil);
|
| + [_appViewController showMenuAnimated:animated];
|
| +}
|
| +
|
| +- (void)hideMenuAnimated:(BOOL)animated {
|
| + DCHECK(_appViewController != nil);
|
| + [_appViewController hideMenuAnimated:animated];
|
| +}
|
| +
|
| +- (void)presentSignInFlow {
|
| + DCHECK(_appViewController != nil);
|
| + [_appViewController presentSignInFlow];
|
| +}
|
| +
|
| +#pragma mark - Properties
|
| +
|
| ++ (AppDelegate*)instance {
|
| + return (AppDelegate*)UIApplication.sharedApplication.delegate;
|
| +}
|
| +
|
| +#pragma mark - Private
|
| +
|
| - (void)launchRemotingViewController {
|
| RemotingViewController* vc = [[RemotingViewController alloc] init];
|
| UINavigationController* navController =
|
| [[UINavigationController alloc] initWithRootViewController:vc];
|
| navController.navigationBarHidden = true;
|
| - self.window.rootViewController = navController;
|
| +
|
| + _appViewController =
|
| + [[AppViewController alloc] initWithMainViewController:navController];
|
| + self.window.rootViewController = _appViewController;
|
| [self.window makeKeyAndVisible];
|
| }
|
|
|
|
|