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

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

Issue 2845763002: Remove DeviceLightEvent implementation (Closed)
Patch Set: same as previous patch Created 3 years, 7 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
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/public/test/layouttest_support.h" 5 #include "content/public/test/layouttest_support.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 #include <utility> 8 #include <utility>
9 9
10 #include "base/callback.h" 10 #include "base/callback.h"
(...skipping 251 matching lines...) Expand 10 before | Expand all | Expand 10 after
262 base::Passed(&autodeleter), callback)); 262 base::Passed(&autodeleter), callback));
263 } 263 }
264 264
265 void SetMockGamepadProvider(std::unique_ptr<RendererGamepadProvider> provider) { 265 void SetMockGamepadProvider(std::unique_ptr<RendererGamepadProvider> provider) {
266 RenderThreadImpl::current() 266 RenderThreadImpl::current()
267 ->blink_platform_impl() 267 ->blink_platform_impl()
268 ->SetPlatformEventObserverForTesting(blink::kWebPlatformEventTypeGamepad, 268 ->SetPlatformEventObserverForTesting(blink::kWebPlatformEventTypeGamepad,
269 std::move(provider)); 269 std::move(provider));
270 } 270 }
271 271
272 void SetMockDeviceLightData(const double data) {
273 RendererBlinkPlatformImpl::SetMockDeviceLightDataForTesting(data);
274 }
275
276 void SetMockDeviceMotionData(const MotionData& data) { 272 void SetMockDeviceMotionData(const MotionData& data) {
277 RendererBlinkPlatformImpl::SetMockDeviceMotionDataForTesting(data); 273 RendererBlinkPlatformImpl::SetMockDeviceMotionDataForTesting(data);
278 } 274 }
279 275
280 void SetMockDeviceOrientationData(const OrientationData& data) { 276 void SetMockDeviceOrientationData(const OrientationData& data) {
281 RendererBlinkPlatformImpl::SetMockDeviceOrientationDataForTesting(data); 277 RendererBlinkPlatformImpl::SetMockDeviceOrientationDataForTesting(data);
282 } 278 }
283 279
284 namespace { 280 namespace {
285 281
(...skipping 315 matching lines...) Expand 10 before | Expand all | Expand 10 after
601 } 597 }
602 } 598 }
603 599
604 bool IsNavigationInitiatedByRenderer(const blink::WebURLRequest& request) { 600 bool IsNavigationInitiatedByRenderer(const blink::WebURLRequest& request) {
605 RequestExtraData* extra_data = 601 RequestExtraData* extra_data =
606 static_cast<RequestExtraData*>(request.GetExtraData()); 602 static_cast<RequestExtraData*>(request.GetExtraData());
607 return extra_data && extra_data->navigation_initiated_by_renderer(); 603 return extra_data && extra_data->navigation_initiated_by_renderer();
608 } 604 }
609 605
610 } // namespace content 606 } // namespace content
OLDNEW
« no previous file with comments | « content/test/data/device_sensors/device_light_test.html ('k') | device/generic_sensor/platform_sensor_ambient_light_mac.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698