OLD | NEW |
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/public/test/mock_render_thread.h" | 5 #include "content/public/test/mock_render_thread.h" |
6 | 6 |
7 #include "base/message_loop/message_loop_proxy.h" | 7 #include "base/message_loop/message_loop_proxy.h" |
8 #include "content/common/frame_messages.h" | 8 #include "content/common/frame_messages.h" |
9 #include "content/common/view_messages.h" | 9 #include "content/common/view_messages.h" |
10 #include "content/public/renderer/render_process_observer.h" | 10 #include "content/public/renderer/render_process_observer.h" |
(...skipping 170 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
181 | 181 |
182 #if defined(OS_WIN) | 182 #if defined(OS_WIN) |
183 void MockRenderThread::PreCacheFont(const LOGFONT& log_font) { | 183 void MockRenderThread::PreCacheFont(const LOGFONT& log_font) { |
184 } | 184 } |
185 | 185 |
186 void MockRenderThread::ReleaseCachedFonts() { | 186 void MockRenderThread::ReleaseCachedFonts() { |
187 } | 187 } |
188 | 188 |
189 #endif // OS_WIN | 189 #endif // OS_WIN |
190 | 190 |
191 ServiceRegistry* MockRenderThread::GetServiceRegistry() { | |
192 return NULL; | |
193 } | |
194 | |
195 void MockRenderThread::SendCloseMessage() { | 191 void MockRenderThread::SendCloseMessage() { |
196 ViewMsg_Close msg(routing_id_); | 192 ViewMsg_Close msg(routing_id_); |
197 RenderViewImpl::FromRoutingID(routing_id_)->OnMessageReceived(msg); | 193 RenderViewImpl::FromRoutingID(routing_id_)->OnMessageReceived(msg); |
198 } | 194 } |
199 | 195 |
200 // The Widget expects to be returned valid route_id. | 196 // The Widget expects to be returned valid route_id. |
201 void MockRenderThread::OnCreateWidget(int opener_id, | 197 void MockRenderThread::OnCreateWidget(int opener_id, |
202 blink::WebPopupType popup_type, | 198 blink::WebPopupType popup_type, |
203 int* route_id, | 199 int* route_id, |
204 int* surface_id) { | 200 int* surface_id) { |
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
255 void MockRenderThread::OnDuplicateSection( | 251 void MockRenderThread::OnDuplicateSection( |
256 base::SharedMemoryHandle renderer_handle, | 252 base::SharedMemoryHandle renderer_handle, |
257 base::SharedMemoryHandle* browser_handle) { | 253 base::SharedMemoryHandle* browser_handle) { |
258 // We don't have to duplicate the input handles since RenderViewTest does not | 254 // We don't have to duplicate the input handles since RenderViewTest does not |
259 // separate a browser process from a renderer process. | 255 // separate a browser process from a renderer process. |
260 *browser_handle = renderer_handle; | 256 *browser_handle = renderer_handle; |
261 } | 257 } |
262 #endif // defined(OS_WIN) | 258 #endif // defined(OS_WIN) |
263 | 259 |
264 } // namespace content | 260 } // namespace content |
OLD | NEW |