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

Side by Side Diff: content/test/test_renderer_host.cc

Issue 10082021: TabContents -> WebContentsImpl, part 13. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 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) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 "content/test/test_renderer_host.h" 5 #include "content/test/test_renderer_host.h"
6 6
7 #include "content/browser/renderer_host/render_view_host_factory.h" 7 #include "content/browser/renderer_host/render_view_host_factory.h"
8 #include "content/browser/renderer_host/test_render_view_host.h" 8 #include "content/browser/renderer_host/test_render_view_host.h"
9 #include "content/browser/site_instance_impl.h" 9 #include "content/browser/site_instance_impl.h"
10 #include "content/browser/web_contents/navigation_entry_impl.h" 10 #include "content/browser/web_contents/navigation_entry_impl.h"
(...skipping 84 matching lines...) Expand 10 before | Expand all | Expand 10 after
95 // static 95 // static
96 void RenderViewHostTester::EnableAccessibilityUpdatedNotifications( 96 void RenderViewHostTester::EnableAccessibilityUpdatedNotifications(
97 RenderViewHost* host) { 97 RenderViewHost* host) {
98 static_cast<RenderViewHostImpl*>( 98 static_cast<RenderViewHostImpl*>(
99 host)->set_send_accessibility_updated_notifications(true); 99 host)->set_send_accessibility_updated_notifications(true);
100 } 100 }
101 101
102 // static 102 // static
103 RenderViewHost* RenderViewHostTester::GetPendingForController( 103 RenderViewHost* RenderViewHostTester::GetPendingForController(
104 NavigationController* controller) { 104 NavigationController* controller) {
105 TabContents* tab_contents = static_cast<TabContents*>( 105 WebContentsImpl* web_contents = static_cast<WebContentsImpl*>(
106 controller->GetWebContents()); 106 controller->GetWebContents());
107 return tab_contents->GetRenderManagerForTesting()->pending_render_view_host(); 107 return web_contents->GetRenderManagerForTesting()->pending_render_view_host();
108 } 108 }
109 109
110 // static 110 // static
111 bool RenderViewHostTester::IsRenderViewHostSwappedOut(RenderViewHost* rvh) { 111 bool RenderViewHostTester::IsRenderViewHostSwappedOut(RenderViewHost* rvh) {
112 return static_cast<RenderViewHostImpl*>(rvh)->is_swapped_out(); 112 return static_cast<RenderViewHostImpl*>(rvh)->is_swapped_out();
113 } 113 }
114 114
115 // static 115 // static
116 bool RenderViewHostTester::TestOnMessageReceived(RenderViewHost* rvh, 116 bool RenderViewHostTester::TestOnMessageReceived(RenderViewHost* rvh,
117 const IPC::Message& msg) { 117 const IPC::Message& msg) {
(...skipping 104 matching lines...) Expand 10 before | Expand all | Expand 10 after
222 message_loop_.DeleteSoon(FROM_HERE, browser_context_.release()); 222 message_loop_.DeleteSoon(FROM_HERE, browser_context_.release());
223 message_loop_.RunAllPending(); 223 message_loop_.RunAllPending();
224 } 224 }
225 225
226 void RenderViewHostTestHarness::SetRenderProcessHostFactory( 226 void RenderViewHostTestHarness::SetRenderProcessHostFactory(
227 RenderProcessHostFactory* factory) { 227 RenderProcessHostFactory* factory) {
228 rvh_test_enabler_.rvh_factory_->set_render_process_host_factory(factory); 228 rvh_test_enabler_.rvh_factory_->set_render_process_host_factory(factory);
229 } 229 }
230 230
231 } // namespace content 231 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698