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

Unified Diff: content/renderer/renderer_webkitplatformsupport_impl.cc

Issue 302553007: Call RenderViewImpl::SetScreenOrientationForTesting to make sure that events are not sent when orie… (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Updated by review comments. Created 6 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 side-by-side diff with in-line comments
Download patch
Index: content/renderer/renderer_webkitplatformsupport_impl.cc
diff --git a/content/renderer/renderer_webkitplatformsupport_impl.cc b/content/renderer/renderer_webkitplatformsupport_impl.cc
index 433cca128460c80fe3c84eeac8fa56c3714c8fa0..eba4a861dfd9f29c012a1cb7a3bfaf2fe333c01b 100644
--- a/content/renderer/renderer_webkitplatformsupport_impl.cc
+++ b/content/renderer/renderer_webkitplatformsupport_impl.cc
@@ -1080,6 +1080,7 @@ void RendererWebKitPlatformSupportImpl::SetMockDeviceMotionDataForTesting(
// static
void RendererWebKitPlatformSupportImpl::ResetMockScreenOrientationForTesting()
{
+ assert(!(g_test_screen_orientation_controller == 0));
jochen (gone - plz use gerrit) 2014/06/02 07:21:25 DCHECK(g_test_screen_orientation_controller)
ostap 2014/06/03 00:11:54 LazyInstance implements only == operator, so it ha
g_test_screen_orientation_controller.Get().ResetData();
jochen (gone - plz use gerrit) 2014/06/02 07:21:25 .Get() will create an controller btw
ostap 2014/06/03 00:11:54 Yes. ResetMockScreenOrientationForTesting() should
}
@@ -1164,9 +1165,10 @@ void RendererWebKitPlatformSupportImpl::unlockOrientation() {
// static
void RendererWebKitPlatformSupportImpl::SetMockScreenOrientationForTesting(
+ RenderView* render_view,
blink::WebScreenOrientationType orientation) {
g_test_screen_orientation_controller.Get()
- .UpdateDeviceOrientation(orientation);
+ .UpdateDeviceOrientation(render_view, orientation);
}
//------------------------------------------------------------------------------

Powered by Google App Engine
This is Rietveld 408576698