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

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

Issue 2501863003: Support for AudioContextOptions latencyHint. (Closed)
Patch Set: More fixes based on reviewer comments. Created 4 years 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 176 matching lines...) Expand 10 before | Expand all | Expand 10 after
187 } 187 }
188 188
189 WebMIDIAccessor* 189 WebMIDIAccessor*
190 LayoutTestContentRendererClient::OverrideCreateMIDIAccessor( 190 LayoutTestContentRendererClient::OverrideCreateMIDIAccessor(
191 WebMIDIAccessorClient* client) { 191 WebMIDIAccessorClient* client) {
192 test_runner::WebTestInterfaces* interfaces = 192 test_runner::WebTestInterfaces* interfaces =
193 LayoutTestRenderThreadObserver::GetInstance()->test_interfaces(); 193 LayoutTestRenderThreadObserver::GetInstance()->test_interfaces();
194 return interfaces->CreateMIDIAccessor(client); 194 return interfaces->CreateMIDIAccessor(client);
195 } 195 }
196 196
197 WebAudioDevice* 197 WebAudioDevice* LayoutTestContentRendererClient::OverrideCreateAudioDevice(
198 LayoutTestContentRendererClient::OverrideCreateAudioDevice( 198 double sample_rate,
199 double sample_rate) { 199 int frames_per_buffer) {
200 test_runner::WebTestInterfaces* interfaces = 200 test_runner::WebTestInterfaces* interfaces =
201 LayoutTestRenderThreadObserver::GetInstance()->test_interfaces(); 201 LayoutTestRenderThreadObserver::GetInstance()->test_interfaces();
202 return interfaces->CreateAudioDevice(sample_rate); 202 return interfaces->CreateAudioDevice(sample_rate, frames_per_buffer);
203 } 203 }
204 204
205 WebClipboard* LayoutTestContentRendererClient::OverrideWebClipboard() { 205 WebClipboard* LayoutTestContentRendererClient::OverrideWebClipboard() {
206 if (!clipboard_) 206 if (!clipboard_)
207 clipboard_.reset(new MockWebClipboardImpl); 207 clipboard_.reset(new MockWebClipboardImpl);
208 return clipboard_.get(); 208 return clipboard_.get();
209 } 209 }
210 210
211 WebThemeEngine* LayoutTestContentRendererClient::OverrideThemeEngine() { 211 WebThemeEngine* LayoutTestContentRendererClient::OverrideThemeEngine() {
212 return LayoutTestRenderThreadObserver::GetInstance() 212 return LayoutTestRenderThreadObserver::GetInstance()
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after
280 switches::kStableReleaseMode)) { 280 switches::kStableReleaseMode)) {
281 blink::WebRuntimeFeatures::enableTestOnlyFeatures(true); 281 blink::WebRuntimeFeatures::enableTestOnlyFeatures(true);
282 } 282 }
283 if (base::CommandLine::ForCurrentProcess()->HasSwitch( 283 if (base::CommandLine::ForCurrentProcess()->HasSwitch(
284 switches::kEnableFontAntialiasing)) { 284 switches::kEnableFontAntialiasing)) {
285 blink::setFontAntialiasingEnabledForTest(true); 285 blink::setFontAntialiasingEnabledForTest(true);
286 } 286 }
287 } 287 }
288 288
289 } // namespace content 289 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698