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 |
191 void MockRenderThread::SendCloseMessage() { | 195 void MockRenderThread::SendCloseMessage() { |
192 ViewMsg_Close msg(routing_id_); | 196 ViewMsg_Close msg(routing_id_); |
193 RenderViewImpl::FromRoutingID(routing_id_)->OnMessageReceived(msg); | 197 RenderViewImpl::FromRoutingID(routing_id_)->OnMessageReceived(msg); |
194 } | 198 } |
195 | 199 |
196 // The Widget expects to be returned valid route_id. | 200 // The Widget expects to be returned valid route_id. |
197 void MockRenderThread::OnCreateWidget(int opener_id, | 201 void MockRenderThread::OnCreateWidget(int opener_id, |
198 blink::WebPopupType popup_type, | 202 blink::WebPopupType popup_type, |
199 int* route_id, | 203 int* route_id, |
200 int* surface_id) { | 204 int* surface_id) { |
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
251 void MockRenderThread::OnDuplicateSection( | 255 void MockRenderThread::OnDuplicateSection( |
252 base::SharedMemoryHandle renderer_handle, | 256 base::SharedMemoryHandle renderer_handle, |
253 base::SharedMemoryHandle* browser_handle) { | 257 base::SharedMemoryHandle* browser_handle) { |
254 // We don't have to duplicate the input handles since RenderViewTest does not | 258 // We don't have to duplicate the input handles since RenderViewTest does not |
255 // separate a browser process from a renderer process. | 259 // separate a browser process from a renderer process. |
256 *browser_handle = renderer_handle; | 260 *browser_handle = renderer_handle; |
257 } | 261 } |
258 #endif // defined(OS_WIN) | 262 #endif // defined(OS_WIN) |
259 | 263 |
260 } // namespace content | 264 } // namespace content |
OLD | NEW |