OLD | NEW |
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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 #ifndef CHROME_BROWSER_UI_WEBUI_SIGNIN_GET_AUTH_FRAME_H_ | 5 #ifndef CHROME_BROWSER_UI_WEBUI_SIGNIN_SIGNIN_UTILS_H_ |
6 #define CHROME_BROWSER_UI_WEBUI_SIGNIN_GET_AUTH_FRAME_H_ | 6 #define CHROME_BROWSER_UI_WEBUI_SIGNIN_SIGNIN_UTILS_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
| 10 #include "base/values.h" |
| 11 |
| 12 class Browser; |
| 13 |
10 namespace content { | 14 namespace content { |
11 class RenderFrameHost; | 15 class RenderFrameHost; |
12 class WebContents; | 16 class WebContents; |
| 17 class WebUI; |
13 } | 18 } |
14 | 19 |
15 namespace signin { | 20 namespace signin { |
16 | 21 |
17 // Gets a webview within an auth page that has the specified parent frame name | 22 // Gets a webview within an auth page that has the specified parent frame name |
18 // (i.e. <webview name="foobar"></webview>). | 23 // (i.e. <webview name="foobar"></webview>). |
19 content::RenderFrameHost* GetAuthFrame(content::WebContents* web_contents, | 24 content::RenderFrameHost* GetAuthFrame(content::WebContents* web_contents, |
20 const std::string& parent_frame_name); | 25 const std::string& parent_frame_name); |
21 | 26 |
22 content::WebContents* GetAuthFrameWebContents( | 27 content::WebContents* GetAuthFrameWebContents( |
23 content::WebContents* web_contents, | 28 content::WebContents* web_contents, |
24 const std::string& parent_frame_name); | 29 const std::string& parent_frame_name); |
25 | 30 |
| 31 // Gets the browser containing the web UI; if none is found, returns the last |
| 32 // active browser for web UI's profile. |
| 33 Browser* GetDesktopBrowser(content::WebUI* web_ui); |
| 34 |
| 35 // Sets the height of the WebUI modal dialog after its initialization. This is |
| 36 // needed to better accomodate different locales' text heights. |
| 37 void SetInitializedModalHeight(content::WebUI* web_ui, |
| 38 const base::ListValue* args); |
| 39 |
26 } // namespace signin | 40 } // namespace signin |
27 | 41 |
28 #endif // CHROME_BROWSER_UI_WEBUI_SIGNIN_GET_AUTH_FRAME_H_ | 42 #endif // CHROME_BROWSER_UI_WEBUI_SIGNIN_SIGNIN_UTILS_H_ |
OLD | NEW |