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

Side by Side Diff: content/shell/renderer/layout_test/layout_test_content_renderer_client.cc

Issue 2393513004: Convert app banners to use Mojo. (Closed)
Patch Set: Add TODO Created 4 years, 1 month 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) 2014 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2014 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/shell/renderer/layout_test/layout_test_content_renderer_client .h" 5 #include "content/shell/renderer/layout_test/layout_test_content_renderer_client .h"
6 6
7 #include "base/callback.h" 7 #include "base/callback.h"
8 #include "base/command_line.h" 8 #include "base/command_line.h"
9 #include "base/debug/debugger.h" 9 #include "base/debug/debugger.h"
10 #include "components/test_runner/mock_credential_manager_client.h" 10 #include "components/test_runner/mock_credential_manager_client.h"
(...skipping 14 matching lines...) Expand all
25 #include "content/shell/renderer/layout_test/blink_test_runner.h" 25 #include "content/shell/renderer/layout_test/blink_test_runner.h"
26 #include "content/shell/renderer/layout_test/interface_registry_js_wrapper.h" 26 #include "content/shell/renderer/layout_test/interface_registry_js_wrapper.h"
27 #include "content/shell/renderer/layout_test/layout_test_render_frame_observer.h " 27 #include "content/shell/renderer/layout_test/layout_test_render_frame_observer.h "
28 #include "content/shell/renderer/layout_test/layout_test_render_thread_observer. h" 28 #include "content/shell/renderer/layout_test/layout_test_render_thread_observer. h"
29 #include "content/shell/renderer/layout_test/test_media_stream_renderer_factory. h" 29 #include "content/shell/renderer/layout_test/test_media_stream_renderer_factory. h"
30 #include "content/shell/renderer/shell_render_view_observer.h" 30 #include "content/shell/renderer/shell_render_view_observer.h"
31 #include "content/test/mock_webclipboard_impl.h" 31 #include "content/test/mock_webclipboard_impl.h"
32 #include "gin/modules/module_registry.h" 32 #include "gin/modules/module_registry.h"
33 #include "ppapi/shared_impl/ppapi_switches.h" 33 #include "ppapi/shared_impl/ppapi_switches.h"
34 #include "third_party/WebKit/public/platform/WebMediaStreamCenter.h" 34 #include "third_party/WebKit/public/platform/WebMediaStreamCenter.h"
35 #include "third_party/WebKit/public/platform/modules/app_banner/WebAppBannerClie nt.h"
36 #include "third_party/WebKit/public/web/WebFrameWidget.h" 35 #include "third_party/WebKit/public/web/WebFrameWidget.h"
37 #include "third_party/WebKit/public/web/WebKit.h" 36 #include "third_party/WebKit/public/web/WebKit.h"
38 #include "third_party/WebKit/public/web/WebPluginParams.h" 37 #include "third_party/WebKit/public/web/WebPluginParams.h"
39 #include "third_party/WebKit/public/web/WebRuntimeFeatures.h" 38 #include "third_party/WebKit/public/web/WebRuntimeFeatures.h"
40 #include "third_party/WebKit/public/web/WebTestingSupport.h" 39 #include "third_party/WebKit/public/web/WebTestingSupport.h"
41 #include "third_party/WebKit/public/web/WebView.h" 40 #include "third_party/WebKit/public/web/WebView.h"
42 #include "ui/gfx/icc_profile.h" 41 #include "ui/gfx/icc_profile.h"
43 #include "v8/include/v8.h" 42 #include "v8/include/v8.h"
44 43
45 using blink::WebAudioDevice; 44 using blink::WebAudioDevice;
(...skipping 161 matching lines...) Expand 10 before | Expand all | Expand 10 after
207 clipboard_.reset(new MockWebClipboardImpl); 206 clipboard_.reset(new MockWebClipboardImpl);
208 return clipboard_.get(); 207 return clipboard_.get();
209 } 208 }
210 209
211 WebThemeEngine* LayoutTestContentRendererClient::OverrideThemeEngine() { 210 WebThemeEngine* LayoutTestContentRendererClient::OverrideThemeEngine() {
212 return LayoutTestRenderThreadObserver::GetInstance() 211 return LayoutTestRenderThreadObserver::GetInstance()
213 ->test_interfaces() 212 ->test_interfaces()
214 ->ThemeEngine(); 213 ->ThemeEngine();
215 } 214 }
216 215
217 std::unique_ptr<blink::WebAppBannerClient>
218 LayoutTestContentRendererClient::CreateAppBannerClient(
219 RenderFrame* render_frame) {
220 test_runner::WebTestInterfaces* interfaces =
221 LayoutTestRenderThreadObserver::GetInstance()->test_interfaces();
222 return interfaces->CreateAppBannerClient();
223 }
224
225 std::unique_ptr<MediaStreamRendererFactory> 216 std::unique_ptr<MediaStreamRendererFactory>
226 LayoutTestContentRendererClient::CreateMediaStreamRendererFactory() { 217 LayoutTestContentRendererClient::CreateMediaStreamRendererFactory() {
227 #if defined(ENABLE_WEBRTC) 218 #if defined(ENABLE_WEBRTC)
228 return std::unique_ptr<MediaStreamRendererFactory>( 219 return std::unique_ptr<MediaStreamRendererFactory>(
229 new TestMediaStreamRendererFactory()); 220 new TestMediaStreamRendererFactory());
230 #else 221 #else
231 return nullptr; 222 return nullptr;
232 #endif 223 #endif
233 } 224 }
234 225
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after
292 switches::kEnableFontAntialiasing)) { 283 switches::kEnableFontAntialiasing)) {
293 blink::setFontAntialiasingEnabledForTest(true); 284 blink::setFontAntialiasingEnabledForTest(true);
294 } 285 }
295 if (base::CommandLine::ForCurrentProcess()->HasSwitch( 286 if (base::CommandLine::ForCurrentProcess()->HasSwitch(
296 switches::kAlwaysUseComplexText)) { 287 switches::kAlwaysUseComplexText)) {
297 blink::setAlwaysUseComplexTextForTest(true); 288 blink::setAlwaysUseComplexTextForTest(true);
298 } 289 }
299 } 290 }
300 291
301 } // namespace content 292 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698