diff options
author | jam@chromium.org <jam@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-03-31 21:11:41 +0000 |
---|---|---|
committer | jam@chromium.org <jam@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-03-31 21:11:41 +0000 |
commit | 6b5b0cdd4a0f98bd79bb891d0081f53bebaf7765 (patch) | |
tree | e4c2165940c78ca92b9984de2419d754577b2623 /content | |
parent | 12c4b16bf04096402cb1002155a0cb1c83f6a4fb (diff) | |
download | chromium_src-6b5b0cdd4a0f98bd79bb891d0081f53bebaf7765.zip chromium_src-6b5b0cdd4a0f98bd79bb891d0081f53bebaf7765.tar.gz chromium_src-6b5b0cdd4a0f98bd79bb891d0081f53bebaf7765.tar.bz2 |
Send the RENDER_VIEW_HOST_DELETED notification for all RenderViewHost, instead of just ones for TabContents.
BUG=78030
Review URL: http://codereview.chromium.org/6758039
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@80075 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'content')
-rw-r--r-- | content/browser/renderer_host/render_view_host.cc | 5 | ||||
-rw-r--r-- | content/browser/tab_contents/tab_contents.cc | 4 | ||||
-rw-r--r-- | content/common/notification_type.h | 3 |
3 files changed, 7 insertions, 5 deletions
diff --git a/content/browser/renderer_host/render_view_host.cc b/content/browser/renderer_host/render_view_host.cc index 9a5f4c28..97f28cd 100644 --- a/content/browser/renderer_host/render_view_host.cc +++ b/content/browser/renderer_host/render_view_host.cc @@ -120,6 +120,11 @@ RenderViewHost::RenderViewHost(SiteInstance* instance, } RenderViewHost::~RenderViewHost() { + NotificationService::current()->Notify( + NotificationType::RENDER_VIEW_HOST_DELETED, + Source<RenderViewHost>(this), + NotificationService::NoDetails()); + delegate()->RenderViewDeleted(this); // Be sure to clean up any leftover state from cross-site requests. diff --git a/content/browser/tab_contents/tab_contents.cc b/content/browser/tab_contents/tab_contents.cc index 9869999..9559db3 100644 --- a/content/browser/tab_contents/tab_contents.cc +++ b/content/browser/tab_contents/tab_contents.cc @@ -2059,10 +2059,6 @@ void TabContents::RenderViewGone(RenderViewHost* rvh, } void TabContents::RenderViewDeleted(RenderViewHost* rvh) { - NotificationService::current()->Notify( - NotificationType::RENDER_VIEW_HOST_DELETED, - Source<TabContents>(this), - Details<RenderViewHost>(rvh)); render_manager_.RenderViewDeleted(rvh); } diff --git a/content/common/notification_type.h b/content/common/notification_type.h index f0b447d..e04c0b9 100644 --- a/content/common/notification_type.h +++ b/content/common/notification_type.h @@ -483,7 +483,8 @@ class NotificationType { // Used only in testing. RENDER_WIDGET_HOST_DID_RECEIVE_INPUT_EVENT_ACK, - // Sent from ~RenderViewHost. The source is the TabContents. + // Sent from ~RenderViewHost. The source is the RenderViewHost, the details + // unused. RENDER_VIEW_HOST_DELETED, // Sent from RenderViewHost::ClosePage. The hosted RenderView has |