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

Side by Side Diff: chrome/browser/tab_contents/background_contents.cc

Issue 6708114: Revert 79691 - Move WebUIFactory to chrome/browser. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 9 years, 8 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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/tab_contents/background_contents.h" 5 #include "chrome/browser/tab_contents/background_contents.h"
6 6
7 #include "chrome/browser/background_contents_service.h" 7 #include "chrome/browser/background_contents_service.h"
8 #include "chrome/browser/desktop_notification_handler.h" 8 #include "chrome/browser/desktop_notification_handler.h"
9 #include "chrome/browser/profiles/profile.h" 9 #include "chrome/browser/profiles/profile.h"
10 #include "chrome/browser/renderer_preferences_util.h" 10 #include "chrome/browser/renderer_preferences_util.h"
11 #include "chrome/browser/ui/webui/chrome_web_ui_factory.h"
12 #include "chrome/common/extensions/extension_constants.h" 11 #include "chrome/common/extensions/extension_constants.h"
13 #include "chrome/common/extensions/extension_messages.h" 12 #include "chrome/common/extensions/extension_messages.h"
14 #include "chrome/common/url_constants.h" 13 #include "chrome/common/url_constants.h"
15 #include "chrome/common/view_types.h" 14 #include "chrome/common/view_types.h"
16 #include "content/browser/browsing_instance.h" 15 #include "content/browser/browsing_instance.h"
17 #include "content/browser/renderer_host/render_view_host.h" 16 #include "content/browser/renderer_host/render_view_host.h"
18 #include "content/browser/site_instance.h" 17 #include "content/browser/site_instance.h"
19 #include "content/common/notification_service.h" 18 #include "content/common/notification_service.h"
20 #include "content/common/view_messages.h" 19 #include "content/common/view_messages.h"
21 #include "ui/gfx/rect.h" 20 #include "ui/gfx/rect.h"
(...skipping 196 matching lines...) Expand 10 before | Expand all | Expand 10 after
218 render_view_host_->BlockExtensionRequest(params.request_id); 217 render_view_host_->BlockExtensionRequest(params.request_id);
219 } 218 }
220 219
221 void BackgroundContents::CreateNewWindow( 220 void BackgroundContents::CreateNewWindow(
222 int route_id, 221 int route_id,
223 const ViewHostMsg_CreateWindow_Params& params) { 222 const ViewHostMsg_CreateWindow_Params& params) {
224 delegate_view_helper_.CreateNewWindow( 223 delegate_view_helper_.CreateNewWindow(
225 route_id, 224 route_id,
226 render_view_host_->process()->profile(), 225 render_view_host_->process()->profile(),
227 render_view_host_->site_instance(), 226 render_view_host_->site_instance(),
228 ChromeWebUIFactory::GetInstance()->GetWebUIType( 227 WebUIFactory::GetWebUIType(render_view_host_->process()->profile(), url_),
229 render_view_host_->process()->profile(), url_),
230 this, 228 this,
231 params.window_container_type, 229 params.window_container_type,
232 params.frame_name); 230 params.frame_name);
233 } 231 }
234 232
235 void BackgroundContents::CreateNewWidget(int route_id, 233 void BackgroundContents::CreateNewWidget(int route_id,
236 WebKit::WebPopupType popup_type) { 234 WebKit::WebPopupType popup_type) {
237 NOTREACHED(); 235 NOTREACHED();
238 } 236 }
239 237
(...skipping 23 matching lines...) Expand all
263 BackgroundContents* 261 BackgroundContents*
264 BackgroundContents::GetBackgroundContentsByID(int render_process_id, 262 BackgroundContents::GetBackgroundContentsByID(int render_process_id,
265 int render_view_id) { 263 int render_view_id) {
266 RenderViewHost* render_view_host = 264 RenderViewHost* render_view_host =
267 RenderViewHost::FromID(render_process_id, render_view_id); 265 RenderViewHost::FromID(render_process_id, render_view_id);
268 if (!render_view_host) 266 if (!render_view_host)
269 return NULL; 267 return NULL;
270 268
271 return render_view_host->delegate()->GetAsBackgroundContents(); 269 return render_view_host->delegate()->GetAsBackgroundContents();
272 } 270 }
OLDNEW
« no previous file with comments | « chrome/browser/tab_contents/background_contents.h ('k') | chrome/browser/tab_contents/render_view_host_delegate_helper.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698