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

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

Issue 10961066: Revert 158199 - extensions: Add ExtensionView interface. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 8 years, 2 months 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) 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_POPUP_H_ 5 #ifndef CHROME_BROWSER_UI_VIEWS_EXTENSIONS_EXTENSION_POPUP_H_
6 #define CHROME_BROWSER_UI_VIEWS_EXTENSIONS_EXTENSION_POPUP_H_ 6 #define CHROME_BROWSER_UI_VIEWS_EXTENSIONS_EXTENSION_POPUP_H_
7 7
8 #include "base/compiler_specific.h" 8 #include "base/compiler_specific.h"
9 #include "chrome/browser/extensions/extension_host.h" 9 #include "chrome/browser/extensions/extension_host.h"
10 #include "chrome/browser/extensions/extension_view_container.h" 10 #include "chrome/browser/ui/views/extensions/extension_view_views.h"
11 #include "content/public/browser/notification_observer.h" 11 #include "content/public/browser/notification_observer.h"
12 #include "googleurl/src/gurl.h" 12 #include "googleurl/src/gurl.h"
13 #include "ui/views/bubble/bubble_delegate.h" 13 #include "ui/views/bubble/bubble_delegate.h"
14 #include "ui/views/focus/widget_focus_manager.h" 14 #include "ui/views/focus/widget_focus_manager.h"
15 15
16 class Browser; 16 class Browser;
17 17
18 class ExtensionPopup : public views::BubbleDelegateView, 18 class ExtensionPopup : public views::BubbleDelegateView,
19 public ExtensionViewContainer, 19 public ExtensionViewViews::Container,
20 public content::NotificationObserver, 20 public content::NotificationObserver,
21 public views::WidgetFocusChangeListener { 21 public views::WidgetFocusChangeListener {
22 public: 22 public:
23 enum ShowAction { 23 enum ShowAction {
24 SHOW, 24 SHOW,
25 SHOW_AND_INSPECT 25 SHOW_AND_INSPECT
26 }; 26 };
27 27
28 virtual ~ExtensionPopup(); 28 virtual ~ExtensionPopup();
29 29
(...skipping 14 matching lines...) Expand all
44 views::BubbleBorder::ArrowLocation arrow_location, 44 views::BubbleBorder::ArrowLocation arrow_location,
45 ShowAction show_action); 45 ShowAction show_action);
46 46
47 extensions::ExtensionHost* host() const { return extension_host_.get(); } 47 extensions::ExtensionHost* host() const { return extension_host_.get(); }
48 48
49 // content::NotificationObserver overrides. 49 // content::NotificationObserver overrides.
50 virtual void Observe(int type, 50 virtual void Observe(int type,
51 const content::NotificationSource& source, 51 const content::NotificationSource& source,
52 const content::NotificationDetails& details) OVERRIDE; 52 const content::NotificationDetails& details) OVERRIDE;
53 53
54 // ExtensionViewContainer overrides. 54 // ExtensionViewViews::Container overrides.
55 virtual void OnExtensionSizeChanged(ExtensionView* view, 55 virtual void OnExtensionSizeChanged(ExtensionViewViews* view) OVERRIDE;
56 const gfx::Size& new_size) OVERRIDE;
57 virtual void OnExtensionViewDidShow(ExtensionView* view) OVERRIDE;
58 56
59 // views::View overrides. 57 // views::View overrides.
60 virtual gfx::Size GetPreferredSize() OVERRIDE; 58 virtual gfx::Size GetPreferredSize() OVERRIDE;
61 59
62 // views::WidgetFocusChangeListener overrides. 60 // views::WidgetFocusChangeListener overrides.
63 virtual void OnNativeFocusChange(gfx::NativeView focused_before, 61 virtual void OnNativeFocusChange(gfx::NativeView focused_before,
64 gfx::NativeView focused_now) OVERRIDE; 62 gfx::NativeView focused_now) OVERRIDE;
65 63
66 // The min/max height of popups. 64 // The min/max height of popups.
67 static const int kMinWidth; 65 static const int kMinWidth;
(...skipping 21 matching lines...) Expand all
89 bool inspect_with_devtools_; 87 bool inspect_with_devtools_;
90 88
91 content::NotificationRegistrar registrar_; 89 content::NotificationRegistrar registrar_;
92 90
93 base::WeakPtrFactory<ExtensionPopup> close_bubble_factory_; 91 base::WeakPtrFactory<ExtensionPopup> close_bubble_factory_;
94 92
95 DISALLOW_COPY_AND_ASSIGN(ExtensionPopup); 93 DISALLOW_COPY_AND_ASSIGN(ExtensionPopup);
96 }; 94 };
97 95
98 #endif // CHROME_BROWSER_UI_VIEWS_EXTENSIONS_EXTENSION_POPUP_H_ 96 #endif // CHROME_BROWSER_UI_VIEWS_EXTENSIONS_EXTENSION_POPUP_H_
OLDNEW
« no previous file with comments | « chrome/browser/ui/views/extensions/extension_dialog.cc ('k') | chrome/browser/ui/views/extensions/extension_popup.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698