summaryrefslogtreecommitdiffstats
path: root/chrome/browser/blocked_popup_container.h
diff options
context:
space:
mode:
authorjamesr@chromium.org <jamesr@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-12-16 01:07:08 +0000
committerjamesr@chromium.org <jamesr@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-12-16 01:07:08 +0000
commit135fd3b65dac543c78543f85f83b4d0ea83d5184 (patch)
tree154c664fec0b39e5f263cc7a8616c4cdcb983d1d /chrome/browser/blocked_popup_container.h
parent20cb5f48d36abeb25bbf6cdd6a5f6debe014e8b1 (diff)
downloadchromium_src-135fd3b65dac543c78543f85f83b4d0ea83d5184.zip
chromium_src-135fd3b65dac543c78543f85f83b4d0ea83d5184.tar.gz
chromium_src-135fd3b65dac543c78543f85f83b4d0ea83d5184.tar.bz2
Give classes with virtual methods virtual protected d'tors instead of non-virtual public implicit d'tors.
Was originally: Replace public nonvirtual destructors in classes with virtual members with protected nonvirtual destructors where possible, and with public virtual destructors where destruction of a derived class occurs. (chrome/browser/[a-m]* only) (Part 4 of http://www.gotw.ca/publications/mill18.htm has a rationale for why public nonvirtual destructors in classes with virtual members is dangerous.) BUG=none TEST=base_unittests & app_unittests Review URL: http://codereview.chromium.org/201100 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@34634 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/blocked_popup_container.h')
-rw-r--r--chrome/browser/blocked_popup_container.h14
1 files changed, 8 insertions, 6 deletions
diff --git a/chrome/browser/blocked_popup_container.h b/chrome/browser/blocked_popup_container.h
index 2d5ef6a..c3c5682 100644
--- a/chrome/browser/blocked_popup_container.h
+++ b/chrome/browser/blocked_popup_container.h
@@ -52,6 +52,8 @@ class BlockedPopupContainerView {
// Called by the BlockedPopupContainer that owns us. Destroys the view or
// starts a delayed Task to destroy the View at some later time.
virtual void Destroy() = 0;
+
+ virtual ~BlockedPopupContainerView() {}
};
// Takes ownership of TabContents that are unrequested popup windows and
@@ -160,7 +162,7 @@ class BlockedPopupContainer : public TabContentsDelegate,
// Ignored; BlockedPopupContainer doesn't display a throbber.
virtual void NavigationStateChanged(const TabContents* source,
- unsigned changed_flags) { }
+ unsigned changed_flags) {}
// Forwards AddNewContents to our |owner_|.
virtual void AddNewContents(TabContents* source,
@@ -170,10 +172,10 @@ class BlockedPopupContainer : public TabContentsDelegate,
bool user_gesture);
// Ignore activation requests from the TabContents we're blocking.
- virtual void ActivateContents(TabContents* contents) { }
+ virtual void ActivateContents(TabContents* contents) {}
// Ignored; BlockedPopupContainer doesn't display a throbber.
- virtual void LoadingStateChanged(TabContents* source) { }
+ virtual void LoadingStateChanged(TabContents* source) {}
// Removes |source| from our internal list of blocked popups.
virtual void CloseContents(TabContents* source);
@@ -188,13 +190,13 @@ class BlockedPopupContainer : public TabContentsDelegate,
virtual TabContents* GetConstrainingContents(TabContents* source);
// Ignored; BlockedPopupContainer doesn't display a toolbar.
- virtual void ToolbarSizeChanged(TabContents* source, bool is_animating) { }
+ virtual void ToolbarSizeChanged(TabContents* source, bool is_animating) {}
// Ignored; BlockedPopupContainer doesn't display a bookmarking star.
- virtual void URLStarredChanged(TabContents* source, bool starred) { }
+ virtual void URLStarredChanged(TabContents* source, bool starred) {}
// Ignored; BlockedPopupContainer doesn't display a URL bar.
- virtual void UpdateTargetURL(TabContents* source, const GURL& url) { }
+ virtual void UpdateTargetURL(TabContents* source, const GURL& url) {}
// A number larger than the internal popup count on the Renderer; meant for
// preventing a compromised renderer from exhausting GDI memory by spawning