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 COMPONENTS_APP_MODAL_APP_MODAL_DIALOG_H_ | 5 #ifndef COMPONENTS_APP_MODAL_APP_MODAL_DIALOG_H_ |
6 #define COMPONENTS_APP_MODAL_APP_MODAL_DIALOG_H_ | 6 #define COMPONENTS_APP_MODAL_APP_MODAL_DIALOG_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
11 #include "base/strings/string16.h" | 11 #include "base/strings/string16.h" |
12 #include "build/build_config.h" | 12 #include "build/build_config.h" |
13 | 13 |
14 class NativeAppModalDialog; | |
15 | |
16 namespace content { | 14 namespace content { |
17 class WebContents; | 15 class WebContents; |
18 } | 16 } |
19 | 17 |
| 18 namespace app_modal { |
| 19 |
| 20 class NativeAppModalDialog; |
| 21 |
20 // A controller+model base class for modal dialogs. | 22 // A controller+model base class for modal dialogs. |
21 class AppModalDialog { | 23 class AppModalDialog { |
22 public: | 24 public: |
23 // A union of data necessary to determine the type of message box to | 25 // A union of data necessary to determine the type of message box to |
24 // show. | 26 // show. |
25 AppModalDialog(content::WebContents* web_contents, | 27 AppModalDialog(content::WebContents* web_contents, |
26 const base::string16& title); | 28 const base::string16& title); |
27 virtual ~AppModalDialog(); | 29 virtual ~AppModalDialog(); |
28 | 30 |
29 // Called by the AppModalDialogQueue to show this dialog. | 31 // Called by the AppModalDialogQueue to show this dialog. |
(...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
95 AppModalDialogObserver(); | 97 AppModalDialogObserver(); |
96 virtual ~AppModalDialogObserver(); | 98 virtual ~AppModalDialogObserver(); |
97 | 99 |
98 // Called when the modal dialog is shown. | 100 // Called when the modal dialog is shown. |
99 virtual void Notify(AppModalDialog* dialog) = 0; | 101 virtual void Notify(AppModalDialog* dialog) = 0; |
100 | 102 |
101 private: | 103 private: |
102 DISALLOW_COPY_AND_ASSIGN(AppModalDialogObserver); | 104 DISALLOW_COPY_AND_ASSIGN(AppModalDialogObserver); |
103 }; | 105 }; |
104 | 106 |
| 107 } // namespace app_modal |
| 108 |
105 #endif // COMPONENTS_APP_MODAL_APP_MODAL_DIALOG_H_ | 109 #endif // COMPONENTS_APP_MODAL_APP_MODAL_DIALOG_H_ |
OLD | NEW |