diff options
author | pkasting@chromium.org <pkasting@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-01-21 19:01:19 +0000 |
---|---|---|
committer | pkasting@chromium.org <pkasting@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-01-21 19:01:19 +0000 |
commit | f4f50efb4d3ee42470c8057345e902ac42e76801 (patch) | |
tree | 5b4d0c57cd94d8169db9dc441f424d6443e4f490 /chrome/browser/extensions/extension_infobar_delegate.h | |
parent | 0bd22cab9c919ff8d9b35153f6799dc031fe2770 (diff) | |
download | chromium_src-f4f50efb4d3ee42470c8057345e902ac42e76801.zip chromium_src-f4f50efb4d3ee42470c8057345e902ac42e76801.tar.gz chromium_src-f4f50efb4d3ee42470c8057345e902ac42e76801.tar.bz2 |
Cleanup: de-inline a bunch of classes, rename and move "PluginInstaller" to "PluginInstallerInfoBarDelegate" for clarity, lots of other misc. stuff
BUG=none
TEST=none
Review URL: http://codereview.chromium.org/6249010
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@72166 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/extensions/extension_infobar_delegate.h')
-rw-r--r-- | chrome/browser/extensions/extension_infobar_delegate.h | 29 |
1 files changed, 15 insertions, 14 deletions
diff --git a/chrome/browser/extensions/extension_infobar_delegate.h b/chrome/browser/extensions/extension_infobar_delegate.h index f286a11..43ca959 100644 --- a/chrome/browser/extensions/extension_infobar_delegate.h +++ b/chrome/browser/extensions/extension_infobar_delegate.h @@ -1,4 +1,4 @@ -// Copyright (c) 2010 The Chromium Authors. All rights reserved. +// Copyright (c) 2011 The Chromium Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. @@ -27,30 +27,33 @@ class ExtensionInfoBarDelegate : public InfoBarDelegate, virtual ~DelegateObserver() {} }; - ExtensionInfoBarDelegate(Browser* browser, TabContents* contents, - const Extension* extension, const GURL& url); - ~ExtensionInfoBarDelegate(); - + ExtensionInfoBarDelegate(Browser* browser, + TabContents* contents, + const Extension* extension, + const GURL& url); const Extension* extension() { return extension_; } ExtensionHost* extension_host() { return extension_host_.get(); } void set_observer(DelegateObserver* observer) { observer_ = observer; } - // Overridden from InfoBarDelegate: - virtual void InfoBarDismissed(); + bool closing() { return closing_; } + + private: + virtual ~ExtensionInfoBarDelegate(); + + // InfoBarDelegate: + virtual InfoBar* CreateInfoBar(); virtual bool EqualsDelegate(InfoBarDelegate* delegate) const; + virtual void InfoBarDismissed(); virtual void InfoBarClosed(); - virtual InfoBar* CreateInfoBar(); + virtual Type GetInfoBarType() const; virtual ExtensionInfoBarDelegate* AsExtensionInfoBarDelegate(); - virtual Type GetInfoBarType(); - // Overridden from NotificationObserver: + // NotificationObserver: virtual void Observe(NotificationType type, const NotificationSource& source, const NotificationDetails& details); - bool closing() { return closing_; } - private: // The extension host we are showing the InfoBar for. The delegate needs to // own this since the InfoBar gets deleted and recreated when you switch tabs // and come back (and we don't want the user's interaction with the InfoBar to @@ -61,9 +64,7 @@ class ExtensionInfoBarDelegate : public InfoBarDelegate, DelegateObserver* observer_; const Extension* extension_; - TabContents* tab_contents_; - NotificationRegistrar registrar_; // Whether we are currently animating to close. This is used to ignore |