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 CHROME_BROWSER_UI_VIEWS_EXTENSIONS_EXTENSION_DIALOG_H_ | 5 #ifndef CHROME_BROWSER_UI_VIEWS_EXTENSIONS_EXTENSION_DIALOG_H_ |
6 #define CHROME_BROWSER_UI_VIEWS_EXTENSIONS_EXTENSION_DIALOG_H_ | 6 #define CHROME_BROWSER_UI_VIEWS_EXTENSIONS_EXTENSION_DIALOG_H_ |
7 | 7 |
8 #include "base/logging.h" | 8 #include "base/logging.h" |
9 #include "base/memory/ref_counted.h" | 9 #include "base/memory/ref_counted.h" |
10 #include "content/public/browser/notification_observer.h" | 10 #include "content/public/browser/notification_observer.h" |
11 #include "content/public/browser/notification_registrar.h" | 11 #include "content/public/browser/notification_registrar.h" |
12 #include "ui/aura/window.h" | 12 #include "ui/aura/window.h" |
13 #include "ui/gfx/native_widget_types.h" | 13 #include "ui/gfx/native_widget_types.h" |
14 #include "ui/views/window/dialog_delegate.h" | 14 #include "ui/views/window/dialog_delegate.h" |
15 | 15 |
16 class ExtensionDialogObserver; | 16 class ExtensionDialogObserver; |
| 17 class ExtensionViewViews; |
17 class GURL; | 18 class GURL; |
18 class Profile; | 19 class Profile; |
19 | 20 |
20 namespace content { | 21 namespace content { |
21 class WebContents; | 22 class WebContents; |
22 } | 23 } |
23 | 24 |
24 namespace extensions { | 25 namespace extensions { |
25 class ExtensionViewHost; | 26 class ExtensionViewHost; |
26 } | 27 } |
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
85 virtual ~ExtensionDialog(); | 86 virtual ~ExtensionDialog(); |
86 | 87 |
87 private: | 88 private: |
88 friend class base::RefCounted<ExtensionDialog>; | 89 friend class base::RefCounted<ExtensionDialog>; |
89 | 90 |
90 // Use Show() to create instances. | 91 // Use Show() to create instances. |
91 ExtensionDialog(extensions::ExtensionViewHost* host, | 92 ExtensionDialog(extensions::ExtensionViewHost* host, |
92 ExtensionDialogObserver* observer); | 93 ExtensionDialogObserver* observer); |
93 | 94 |
94 void InitWindow(aura::Window* parent_window, int width, int height); | 95 void InitWindow(aura::Window* parent_window, int width, int height); |
| 96 ExtensionViewViews* GetExtensionView() const; |
95 | 97 |
96 // Window Title | 98 // Window Title |
97 base::string16 window_title_; | 99 base::string16 window_title_; |
98 | 100 |
99 // The contained host for the view. | 101 // The contained host for the view. |
100 scoped_ptr<extensions::ExtensionViewHost> host_; | 102 scoped_ptr<extensions::ExtensionViewHost> host_; |
101 | 103 |
102 content::NotificationRegistrar registrar_; | 104 content::NotificationRegistrar registrar_; |
103 | 105 |
104 // The observer of this popup. | 106 // The observer of this popup. |
105 ExtensionDialogObserver* observer_; | 107 ExtensionDialogObserver* observer_; |
106 | 108 |
107 DISALLOW_COPY_AND_ASSIGN(ExtensionDialog); | 109 DISALLOW_COPY_AND_ASSIGN(ExtensionDialog); |
108 }; | 110 }; |
109 | 111 |
110 #endif // CHROME_BROWSER_UI_VIEWS_EXTENSIONS_EXTENSION_DIALOG_H_ | 112 #endif // CHROME_BROWSER_UI_VIEWS_EXTENSIONS_EXTENSION_DIALOG_H_ |
OLD | NEW |