OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 UI_WEB_DIALOGS_WEB_DIALOG_DELEGATE_H_ | 5 #ifndef UI_WEB_DIALOGS_WEB_DIALOG_DELEGATE_H_ |
6 #define UI_WEB_DIALOGS_WEB_DIALOG_DELEGATE_H_ | 6 #define UI_WEB_DIALOGS_WEB_DIALOG_DELEGATE_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 20 matching lines...) Expand all Loading... |
31 | 31 |
32 namespace ui { | 32 namespace ui { |
33 | 33 |
34 // Implement this class to receive notifications. | 34 // Implement this class to receive notifications. |
35 class WEB_DIALOGS_EXPORT WebDialogDelegate { | 35 class WEB_DIALOGS_EXPORT WebDialogDelegate { |
36 public: | 36 public: |
37 // Returns true if the contents needs to be run in a modal dialog. | 37 // Returns true if the contents needs to be run in a modal dialog. |
38 virtual ModalType GetDialogModalType() const = 0; | 38 virtual ModalType GetDialogModalType() const = 0; |
39 | 39 |
40 // Returns the title of the dialog. | 40 // Returns the title of the dialog. |
41 virtual string16 GetDialogTitle() const = 0; | 41 virtual base::string16 GetDialogTitle() const = 0; |
42 | 42 |
43 // Returns the dialog's name identifier. Used to identify this dialog for | 43 // Returns the dialog's name identifier. Used to identify this dialog for |
44 // state restoration. | 44 // state restoration. |
45 virtual std::string GetDialogName() const; | 45 virtual std::string GetDialogName() const; |
46 | 46 |
47 // Get the HTML file path for the content to load in the dialog. | 47 // Get the HTML file path for the content to load in the dialog. |
48 virtual GURL GetDialogContentURL() const = 0; | 48 virtual GURL GetDialogContentURL() const = 0; |
49 | 49 |
50 // Get WebUIMessageHandler objects to handle messages from the HTML/JS page. | 50 // Get WebUIMessageHandler objects to handle messages from the HTML/JS page. |
51 // The handlers are used to send and receive messages from the page while it | 51 // The handlers are used to send and receive messages from the page while it |
(...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
120 | 120 |
121 // Stores the dialog bounds. | 121 // Stores the dialog bounds. |
122 virtual void StoreDialogSize(const gfx::Size& dialog_size) {} | 122 virtual void StoreDialogSize(const gfx::Size& dialog_size) {} |
123 | 123 |
124 virtual ~WebDialogDelegate() {} | 124 virtual ~WebDialogDelegate() {} |
125 }; | 125 }; |
126 | 126 |
127 } // namespace ui | 127 } // namespace ui |
128 | 128 |
129 #endif // UI_WEB_DIALOGS_WEB_DIALOG_DELEGATE_H_ | 129 #endif // UI_WEB_DIALOGS_WEB_DIALOG_DELEGATE_H_ |
OLD | NEW |