Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(169)

Side by Side Diff: chrome/browser/ui/views/extensions/extension_dialog.h

Issue 8811001: Oust BubbleWindow from ExtensionDialog, use chromeos::BubbleFrameView directly. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Build requisite and non-breaking chrome/browser/chromeos/frame/ files in aura cros. Created 9 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
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_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 #pragma once 7 #pragma once
8 8
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/views/widget/widget_delegate.h" 12 #include "ui/views/widget/widget_delegate.h"
13 13
14 class Browser; 14 class Browser;
15 class ExtensionDialogObserver; 15 class ExtensionDialogObserver;
16 class ExtensionHost; 16 class ExtensionHost;
17 class GURL; 17 class GURL;
18 class TabContents; 18 class TabContents;
19 19
20 namespace views {
21 class View;
22 class Widget;
23 }
24
25 // Modal dialog containing contents provided by an extension. 20 // Modal dialog containing contents provided by an extension.
26 // Dialog is automatically centered in the browser window and has fixed size. 21 // Dialog is automatically centered in the browser window and has fixed size.
27 // For example, used by the Chrome OS file browser. 22 // For example, used by the Chrome OS file browser.
28 class ExtensionDialog : public views::WidgetDelegate, 23 class ExtensionDialog : public views::WidgetDelegate,
29 public content::NotificationObserver, 24 public content::NotificationObserver,
30 public base::RefCounted<ExtensionDialog> { 25 public base::RefCounted<ExtensionDialog> {
31 public: 26 public:
32 virtual ~ExtensionDialog(); 27 virtual ~ExtensionDialog();
33 28
34 // Create and show a dialog with |url| centered over the browser window. 29 // Create and show a dialog with |url| centered over the browser window.
(...skipping 22 matching lines...) Expand all
57 // views::WidgetDelegate overrides. 52 // views::WidgetDelegate overrides.
58 virtual bool CanResize() const OVERRIDE; 53 virtual bool CanResize() const OVERRIDE;
59 virtual bool IsModal() const OVERRIDE; 54 virtual bool IsModal() const OVERRIDE;
60 virtual bool ShouldShowWindowTitle() const OVERRIDE; 55 virtual bool ShouldShowWindowTitle() const OVERRIDE;
61 virtual string16 GetWindowTitle() const OVERRIDE; 56 virtual string16 GetWindowTitle() const OVERRIDE;
62 virtual void WindowClosing() OVERRIDE; 57 virtual void WindowClosing() OVERRIDE;
63 virtual void DeleteDelegate() OVERRIDE; 58 virtual void DeleteDelegate() OVERRIDE;
64 virtual views::Widget* GetWidget() OVERRIDE; 59 virtual views::Widget* GetWidget() OVERRIDE;
65 virtual const views::Widget* GetWidget() const OVERRIDE; 60 virtual const views::Widget* GetWidget() const OVERRIDE;
66 virtual views::View* GetContentsView() OVERRIDE; 61 virtual views::View* GetContentsView() OVERRIDE;
62 #if defined(OS_CHROMEOS)
63 virtual views::NonClientFrameView* CreateNonClientFrameView() OVERRIDE;
64 #endif
67 65
68 // content::NotificationObserver overrides. 66 // content::NotificationObserver overrides.
69 virtual void Observe(int type, 67 virtual void Observe(int type,
70 const content::NotificationSource& source, 68 const content::NotificationSource& source,
71 const content::NotificationDetails& details) OVERRIDE; 69 const content::NotificationDetails& details) OVERRIDE;
72 70
73 private: 71 private:
74 // Use Show() to create instances. 72 // Use Show() to create instances.
75 ExtensionDialog(ExtensionHost* host, ExtensionDialogObserver* observer); 73 ExtensionDialog(ExtensionHost* host, ExtensionDialogObserver* observer);
76 74
(...skipping 13 matching lines...) Expand all
90 88
91 content::NotificationRegistrar registrar_; 89 content::NotificationRegistrar registrar_;
92 90
93 // The observer of this popup. 91 // The observer of this popup.
94 ExtensionDialogObserver* observer_; 92 ExtensionDialogObserver* observer_;
95 93
96 DISALLOW_COPY_AND_ASSIGN(ExtensionDialog); 94 DISALLOW_COPY_AND_ASSIGN(ExtensionDialog);
97 }; 95 };
98 96
99 #endif // CHROME_BROWSER_UI_VIEWS_EXTENSIONS_EXTENSION_DIALOG_H_ 97 #endif // CHROME_BROWSER_UI_VIEWS_EXTENSIONS_EXTENSION_DIALOG_H_
OLDNEW
« no previous file with comments | « chrome/browser/chromeos/frame/bubble_window_gtk.cc ('k') | chrome/browser/ui/views/extensions/extension_dialog.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698