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

Side by Side Diff: chrome/browser/renderer_host/render_view_host.cc

Issue 3117024: Clean up ExtensionMessageService. (Closed)
Patch Set: comments fixed Created 10 years, 4 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
OLDNEW
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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 #include "chrome/browser/renderer_host/render_view_host.h" 5 #include "chrome/browser/renderer_host/render_view_host.h"
6 6
7 #include <string> 7 #include <string>
8 #include <utility> 8 #include <utility>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 127 matching lines...) Expand 10 before | Expand all | Expand 10 after
138 DCHECK(instance_); 138 DCHECK(instance_);
139 DCHECK(delegate_); 139 DCHECK(delegate_);
140 } 140 }
141 141
142 RenderViewHost::~RenderViewHost() { 142 RenderViewHost::~RenderViewHost() {
143 delegate()->RenderViewDeleted(this); 143 delegate()->RenderViewDeleted(this);
144 144
145 // Be sure to clean up any leftover state from cross-site requests. 145 // Be sure to clean up any leftover state from cross-site requests.
146 Singleton<CrossSiteRequestManager>()->SetHasPendingCrossSiteRequest( 146 Singleton<CrossSiteRequestManager>()->SetHasPendingCrossSiteRequest(
147 process()->id(), routing_id(), false); 147 process()->id(), routing_id(), false);
148
149 NotificationService::current()->Notify(
150 NotificationType::EXTENSION_PORT_DELETED_DEBUG,
151 Source<IPC::Message::Sender>(this),
152 NotificationService::NoDetails());
153 } 148 }
154 149
155 bool RenderViewHost::CreateRenderView(const string16& frame_name) { 150 bool RenderViewHost::CreateRenderView(const string16& frame_name) {
156 DCHECK(!IsRenderViewLive()) << "Creating view twice"; 151 DCHECK(!IsRenderViewLive()) << "Creating view twice";
157 152
158 // The process may (if we're sharing a process with another host that already 153 // The process may (if we're sharing a process with another host that already
159 // initialized it) or may not (we have our own process or the old process 154 // initialized it) or may not (we have our own process or the old process
160 // crashed) have been initialized. Calling Init multiple times will be 155 // crashed) have been initialized. Calling Init multiple times will be
161 // ignored, so this is safe. 156 // ignored, so this is safe.
162 if (!process()->Init(is_extension_process_)) 157 if (!process()->Init(is_extension_process_))
(...skipping 1861 matching lines...) Expand 10 before | Expand all | Expand 10 after
2024 RenderViewHostDelegate::ContentSettings* content_settings_delegate = 2019 RenderViewHostDelegate::ContentSettings* content_settings_delegate =
2025 delegate_->GetContentSettingsDelegate(); 2020 delegate_->GetContentSettingsDelegate();
2026 if (content_settings_delegate) 2021 if (content_settings_delegate)
2027 content_settings_delegate->OnWebDatabaseAccessed( 2022 content_settings_delegate->OnWebDatabaseAccessed(
2028 url, name, display_name, estimated_size, blocked_by_policy); 2023 url, name, display_name, estimated_size, blocked_by_policy);
2029 } 2024 }
2030 2025
2031 void RenderViewHost::OnSetDisplayingPDFContent() { 2026 void RenderViewHost::OnSetDisplayingPDFContent() {
2032 delegate_->SetDisplayingPDFContent(); 2027 delegate_->SetDisplayingPDFContent();
2033 } 2028 }
OLDNEW
« no previous file with comments | « chrome/browser/renderer_host/browser_render_process_host.cc ('k') | chrome/browser/renderer_host/resource_message_filter.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698