OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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_BROWSER_DIALOGS_H_ | 5 #ifndef CHROME_BROWSER_UI_BROWSER_DIALOGS_H_ |
6 #define CHROME_BROWSER_UI_BROWSER_DIALOGS_H_ | 6 #define CHROME_BROWSER_UI_BROWSER_DIALOGS_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include "gfx/native_widget_types.h" | |
10 #include "ipc/ipc_message.h" | 9 #include "ipc/ipc_message.h" |
| 10 #include "ui/gfx/native_widget_types.h" |
11 | 11 |
12 class HtmlDialogUIDelegate; | 12 class HtmlDialogUIDelegate; |
13 class Profile; | 13 class Profile; |
14 | 14 |
15 namespace browser { | 15 namespace browser { |
16 | 16 |
17 #if defined(IPC_MESSAGE_LOG_ENABLED) | 17 #if defined(IPC_MESSAGE_LOG_ENABLED) |
18 | 18 |
19 // The dialog is a singleton. If the dialog is already opened, it won't do | 19 // The dialog is a singleton. If the dialog is already opened, it won't do |
20 // anything, so you can just blindly call this function all you want. | 20 // anything, so you can just blindly call this function all you want. |
21 // This is Called from chrome/browser/browser_about_handler.cc | 21 // This is Called from chrome/browser/browser_about_handler.cc |
22 void ShowAboutIPCDialog(); | 22 void ShowAboutIPCDialog(); |
23 | 23 |
24 #endif // IPC_MESSAGE_LOG_ENABLED | 24 #endif // IPC_MESSAGE_LOG_ENABLED |
25 | 25 |
26 // Creates and shows an HTML dialog with the given delegate and profile. | 26 // Creates and shows an HTML dialog with the given delegate and profile. |
27 // The window is automatically destroyed when it is closed. | 27 // The window is automatically destroyed when it is closed. |
28 // Returns the created window. | 28 // Returns the created window. |
29 // | 29 // |
30 // Make sure to use the returned window only when you know it is safe | 30 // Make sure to use the returned window only when you know it is safe |
31 // to do so, i.e. before OnDialogClosed() is called on the delegate. | 31 // to do so, i.e. before OnDialogClosed() is called on the delegate. |
32 gfx::NativeWindow ShowHtmlDialog(gfx::NativeWindow parent, Profile* profile, | 32 gfx::NativeWindow ShowHtmlDialog(gfx::NativeWindow parent, Profile* profile, |
33 HtmlDialogUIDelegate* delegate); | 33 HtmlDialogUIDelegate* delegate); |
34 | 34 |
35 } // namespace browser | 35 } // namespace browser |
36 | 36 |
37 #endif // CHROME_BROWSER_UI_BROWSER_DIALOGS_H_ | 37 #endif // CHROME_BROWSER_UI_BROWSER_DIALOGS_H_ |
OLD | NEW |