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

Side by Side Diff: chrome/browser/remoting/remoting_setup_flow.cc

Issue 5955001: Remove chromoting host registration from service process. More IPCs to control (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: merges Created 10 years 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | chrome/browser/service/service_process_control.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/browser/remoting/remoting_setup_flow.h" 5 #include "chrome/browser/remoting/remoting_setup_flow.h"
6 6
7 #include "app/gfx/font_util.h" 7 #include "app/gfx/font_util.h"
8 #include "base/json/json_writer.h" 8 #include "base/json/json_writer.h"
9 #include "base/singleton.h" 9 #include "base/singleton.h"
10 #include "base/string_util.h" 10 #include "base/string_util.h"
(...skipping 244 matching lines...) Expand 10 before | Expand all | Expand 10 after
255 GaiaConstants::kRemotingService, 255 GaiaConstants::kRemotingService,
256 "", captcha, 256 "", captcha,
257 GaiaAuthFetcher::HostedAccountsAllowed); 257 GaiaAuthFetcher::HostedAccountsAllowed);
258 } 258 }
259 259
260 /////////////////////////////////////////////////////////////////////////////// 260 ///////////////////////////////////////////////////////////////////////////////
261 // Method called by RemotingServicePRocessHelper 261 // Method called by RemotingServicePRocessHelper
262 void RemotingSetupFlow::OnProcessLaunched() { 262 void RemotingSetupFlow::OnProcessLaunched() {
263 DCHECK(process_control_->is_connected()); 263 DCHECK(process_control_->is_connected());
264 // TODO(hclam): Need to wait for an ACK to be sure that it is actually active. 264 // TODO(hclam): Need to wait for an ACK to be sure that it is actually active.
265 process_control_->EnableRemotingWithTokens(login_, remoting_token_, 265 process_control_->SetRemotingHostCredentials(login_, sync_token_);
266 sync_token_); 266 process_control_->EnableRemotingHost();
267 267
268 // Save the preference that we have completed the setup of remoting. 268 // Save the preference that we have completed the setup of remoting.
269 profile_->GetPrefs()->SetBoolean(prefs::kRemotingHasSetupCompleted, true); 269 profile_->GetPrefs()->SetBoolean(prefs::kRemotingHasSetupCompleted, true);
270 ShowSetupDone(); 270 ShowSetupDone();
271 } 271 }
272 272
273 /////////////////////////////////////////////////////////////////////////////// 273 ///////////////////////////////////////////////////////////////////////////////
274 // Helper methods for showing contents of the DOM UI 274 // Helper methods for showing contents of the DOM UI
275 void RemotingSetupFlow::ShowGaiaLogin(const DictionaryValue& args) { 275 void RemotingSetupFlow::ShowGaiaLogin(const DictionaryValue& args) {
276 if (dom_ui_) 276 if (dom_ui_)
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
309 } 309 }
310 310
311 void RemotingSetupFlow::ExecuteJavascriptInIFrame( 311 void RemotingSetupFlow::ExecuteJavascriptInIFrame(
312 const std::wstring& iframe_xpath, 312 const std::wstring& iframe_xpath,
313 const std::wstring& js) { 313 const std::wstring& js) {
314 if (dom_ui_) { 314 if (dom_ui_) {
315 RenderViewHost* rvh = dom_ui_->tab_contents()->render_view_host(); 315 RenderViewHost* rvh = dom_ui_->tab_contents()->render_view_host();
316 rvh->ExecuteJavascriptInWebFrame(iframe_xpath, js); 316 rvh->ExecuteJavascriptInWebFrame(iframe_xpath, js);
317 } 317 }
318 } 318 }
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/service/service_process_control.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698