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

Unified Diff: chrome/browser/ui/views/infobars/extension_infobar.h

Issue 22694006: Infobar system refactor. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 7 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/ui/views/infobars/extension_infobar.h
===================================================================
--- chrome/browser/ui/views/infobars/extension_infobar.h (revision 238220)
+++ chrome/browser/ui/views/infobars/extension_infobar.h (working copy)
@@ -6,11 +6,11 @@
#define CHROME_BROWSER_UI_VIEWS_INFOBARS_EXTENSION_INFOBAR_H_
#include "base/compiler_specific.h"
-#include "chrome/browser/extensions/extension_infobar_delegate.h"
#include "chrome/browser/ui/views/infobars/infobar_view.h"
#include "ui/views/controls/button/menu_button_listener.h"
class Browser;
+class ExtensionInfoBarDelegate;
namespace views {
class ImageView;
@@ -18,11 +18,9 @@
}
class ExtensionInfoBar : public InfoBarView,
- public ExtensionInfoBarDelegate::DelegateObserver,
public views::MenuButtonListener {
public:
- ExtensionInfoBar(InfoBarService* owner,
- ExtensionInfoBarDelegate* delegate,
+ ExtensionInfoBar(scoped_ptr<ExtensionInfoBarDelegate> delegate,
Browser* browser);
private:
@@ -34,9 +32,6 @@
const ViewHierarchyChangedDetails& details) OVERRIDE;
virtual int ContentMinimumWidth() const OVERRIDE;
- // ExtensionInfoBarDelegate::DelegateObserver:
- virtual void OnDelegateDeleted() OVERRIDE;
-
// views::MenuButtonListener:
virtual void OnMenuButtonClicked(views::View* source,
const gfx::Point& point) OVERRIDE;
@@ -45,11 +40,6 @@
ExtensionInfoBarDelegate* GetDelegate();
- // TODO(pkasting): This shadows InfoBarView::delegate_. Get rid of this once
- // InfoBars own their delegates (and thus we don't need the DelegateObserver
- // functionality). For now, almost everyone should use GetDelegate() instead.
- InfoBarDelegate* delegate_;
-
Browser* browser_;
// The infobar icon used for the extension infobar. The icon can be either a
« no previous file with comments | « chrome/browser/ui/views/infobars/confirm_infobar.cc ('k') | chrome/browser/ui/views/infobars/extension_infobar.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698