Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(451)

Unified Diff: remoting/ios/app/remoting_view_controller.mm

Issue 2937733003: [CRD iOS] Branching internal and external implementations (Closed)
Patch Set: Add the requestSignIn method Created 3 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: remoting/ios/app/remoting_view_controller.mm
diff --git a/remoting/ios/app/remoting_view_controller.mm b/remoting/ios/app/remoting_view_controller.mm
index 99d9166312e5eba5f75a975bab7ea8fc9722c79e..d0efd8a1e65c4566b5ba219a50545f4425aa116e 100644
--- a/remoting/ios/app/remoting_view_controller.mm
+++ b/remoting/ios/app/remoting_view_controller.mm
@@ -13,6 +13,7 @@
#import "ios/third_party/material_components_ios/src/components/AppBar/src/MaterialAppBar.h"
#import "ios/third_party/material_components_ios/src/components/Dialogs/src/MaterialDialogs.h"
#import "ios/third_party/material_components_ios/src/components/Snackbar/src/MaterialSnackbar.h"
+#import "remoting/ios/app/app_delegate.h"
#import "remoting/ios/app/client_connection_view_controller.h"
#import "remoting/ios/app/host_collection_view_controller.h"
#import "remoting/ios/app/host_view_controller.h"
@@ -135,10 +136,7 @@ static CGFloat kHostInset = 5.f;
- (void)viewDidAppear:(BOOL)animated {
[super viewDidAppear:animated];
if (!_isAuthenticated) {
- // TODO(nicholss): This is used as a demo of the app functionality for the
- // moment but the real app will force the login flow if unauthenticated.
- [self didSelectMenu];
- // [self didSelectRefresh];
+ [AppDelegate.instance requestSignIn];
MDCSnackbarMessage* message = [[MDCSnackbarMessage alloc] init];
message.text = @"Please login.";
[MDCSnackbarManager showMessage:message];
@@ -251,9 +249,7 @@ animationControllerForDismissedController:(UIViewController*)dismissed {
}
- (void)didSelectMenu {
- RemotingMenuViewController* menuViewController =
- [[RemotingMenuViewController alloc] init];
- [self presentViewController:menuViewController animated:YES completion:nil];
+ [AppDelegate.instance setMenuVisible:YES animated:YES];
}
- (void)presentStatus {

Powered by Google App Engine
This is Rietveld 408576698