OLD | NEW |
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" |
11 #include "base/utf_string_conversions.h" | 11 #include "base/utf_string_conversions.h" |
12 #include "base/values.h" | 12 #include "base/values.h" |
13 #include "chrome/browser/browser.h" | |
14 #include "chrome/browser/browser_list.h" | |
15 #include "chrome/browser/dom_ui/chrome_url_data_manager.h" | 13 #include "chrome/browser/dom_ui/chrome_url_data_manager.h" |
16 #include "chrome/browser/dom_ui/dom_ui_util.h" | 14 #include "chrome/browser/dom_ui/dom_ui_util.h" |
17 #include "chrome/browser/platform_util.h" | 15 #include "chrome/browser/platform_util.h" |
18 #include "chrome/browser/prefs/pref_service.h" | 16 #include "chrome/browser/prefs/pref_service.h" |
19 #include "chrome/browser/profile.h" | 17 #include "chrome/browser/profile.h" |
20 #include "chrome/browser/remoting/remoting_resources_source.h" | 18 #include "chrome/browser/remoting/remoting_resources_source.h" |
21 #include "chrome/browser/remoting/remoting_setup_message_handler.h" | 19 #include "chrome/browser/remoting/remoting_setup_message_handler.h" |
22 #include "chrome/browser/renderer_host/render_view_host.h" | 20 #include "chrome/browser/renderer_host/render_view_host.h" |
23 #include "chrome/browser/service/service_process_control.h" | 21 #include "chrome/browser/service/service_process_control.h" |
24 #include "chrome/browser/service/service_process_control_manager.h" | 22 #include "chrome/browser/service/service_process_control_manager.h" |
25 #include "chrome/browser/tab_contents/tab_contents.h" | 23 #include "chrome/browser/tab_contents/tab_contents.h" |
| 24 #include "chrome/browser/ui/browser.h" |
| 25 #include "chrome/browser/ui/browser_list.h" |
26 #include "chrome/common/net/gaia/gaia_auth_fetcher.h" | 26 #include "chrome/common/net/gaia/gaia_auth_fetcher.h" |
27 #include "chrome/common/net/gaia/gaia_constants.h" | 27 #include "chrome/common/net/gaia/gaia_constants.h" |
28 #include "chrome/common/net/gaia/google_service_auth_error.h" | 28 #include "chrome/common/net/gaia/google_service_auth_error.h" |
29 #include "chrome/common/pref_names.h" | 29 #include "chrome/common/pref_names.h" |
30 #include "gfx/font.h" | 30 #include "gfx/font.h" |
31 #include "grit/locale_settings.h" | 31 #include "grit/locale_settings.h" |
32 | 32 |
33 static const wchar_t kLoginIFrameXPath[] = L"//iframe[@id='login']"; | 33 static const wchar_t kLoginIFrameXPath[] = L"//iframe[@id='login']"; |
34 static const wchar_t kDoneIframeXPath[] = L"//iframe[@id='done']"; | 34 static const wchar_t kDoneIframeXPath[] = L"//iframe[@id='done']"; |
35 | 35 |
(...skipping 272 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
308 } | 308 } |
309 | 309 |
310 void RemotingSetupFlow::ExecuteJavascriptInIFrame( | 310 void RemotingSetupFlow::ExecuteJavascriptInIFrame( |
311 const std::wstring& iframe_xpath, | 311 const std::wstring& iframe_xpath, |
312 const std::wstring& js) { | 312 const std::wstring& js) { |
313 if (dom_ui_) { | 313 if (dom_ui_) { |
314 RenderViewHost* rvh = dom_ui_->tab_contents()->render_view_host(); | 314 RenderViewHost* rvh = dom_ui_->tab_contents()->render_view_host(); |
315 rvh->ExecuteJavascriptInWebFrame(iframe_xpath, js); | 315 rvh->ExecuteJavascriptInWebFrame(iframe_xpath, js); |
316 } | 316 } |
317 } | 317 } |
OLD | NEW |