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

Unified Diff: remoting/client/ios/facade/remoting_service.mm

Issue 2825403004: Integrating with new rendering for CRD iOS. (Closed)
Patch Set: Adding remoting service changes to this CL, they are dependent. Created 3 years, 8 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/client/ios/facade/remoting_service.mm
diff --git a/remoting/client/ios/facade/remoting_service.mm b/remoting/client/ios/facade/remoting_service.mm
index 778efbd6cb115b42ff07c1b41441195ced9da77d..e0e8f882319a945ebbae296bf6895511d9c2ddfd 100644
--- a/remoting/client/ios/facade/remoting_service.mm
+++ b/remoting/client/ios/facade/remoting_service.mm
@@ -19,6 +19,7 @@
#include "remoting/base/oauth_token_getter_impl.h"
#include "remoting/client/ios/facade/host_info.h"
#include "remoting/client/ios/facade/host_list_fetcher.h"
+#include "remoting/client/ios/facade/ios_client_runtime_delegate.h"
const char kOauthRedirectUrl[] =
"https://chromoting-oauth.talkgadget."
@@ -66,6 +67,7 @@ std::unique_ptr<remoting::OAuthTokenGetter> CreateOAuthTokenWithRefreshToken(
id<RemotingAuthenticationDelegate> _authDelegate;
id<RemotingHostListDelegate> _hostListDelegate;
remoting::HostListFetcher* _hostListFetcher;
+ remoting::IosClientRuntimeDelegate* _clientRuntimeDelegate;
}
@end
@@ -96,6 +98,11 @@ std::unique_ptr<remoting::OAuthTokenGetter> CreateOAuthTokenWithRefreshToken(
_hosts = nil;
_hostListFetcher = new remoting::HostListFetcher(
remoting::ChromotingClientRuntime::GetInstance()->url_requester());
+ _clientRuntimeDelegate =
+ new remoting::IosClientRuntimeDelegate(); // TODO(nicholss): This might
+ // need a pointer back to the
+ // service.
Jamie 2017/04/21 17:43:01 Put this on the line before so it only takes up on
nicholss 2017/04/21 21:00:06 Done.
+ [self runtime]->SetDelegate(_clientRuntimeDelegate);
}
return self;
}
@@ -252,4 +259,11 @@ std::unique_ptr<remoting::OAuthTokenGetter> CreateOAuthTokenWithRefreshToken(
return remoting::ChromotingClientRuntime::GetInstance();
}
+- (void)callbackWithAccessToken:
+ (const remoting::OAuthTokenGetter::TokenCallback&)onAccessToken {
+ if (_tokenGetter) {
+ _tokenGetter->CallWithToken(onAccessToken);
+ }
+}
+
@end

Powered by Google App Engine
This is Rietveld 408576698