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/layouttest_support.h" | 5 #include "content/public/test/layouttest_support.h" |
6 | 6 |
7 #include "base/callback.h" | 7 #include "base/callback.h" |
8 #include "base/lazy_instance.h" | 8 #include "base/lazy_instance.h" |
9 #include "content/browser/renderer_host/render_widget_host_impl.h" | 9 #include "content/browser/renderer_host/render_widget_host_impl.h" |
10 #include "content/common/gpu/image_transport_surface.h" | 10 #include "content/common/gpu/image_transport_surface.h" |
(...skipping 90 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
101 RendererWebKitPlatformSupportImpl:: | 101 RendererWebKitPlatformSupportImpl:: |
102 SetMockDeviceOrientationDataForTesting(data); | 102 SetMockDeviceOrientationDataForTesting(data); |
103 } | 103 } |
104 | 104 |
105 void SetMockScreenOrientation( | 105 void SetMockScreenOrientation( |
106 const blink::WebScreenOrientationType& orientation) { | 106 const blink::WebScreenOrientationType& orientation) { |
107 RendererWebKitPlatformSupportImpl:: | 107 RendererWebKitPlatformSupportImpl:: |
108 SetMockScreenOrientationForTesting(orientation); | 108 SetMockScreenOrientationForTesting(orientation); |
109 } | 109 } |
110 | 110 |
| 111 void ResetMockScreenOrientation() |
| 112 { |
| 113 RendererWebKitPlatformSupportImpl::ResetMockScreenOrientationForTesting(); |
| 114 } |
| 115 |
111 void EnableRendererLayoutTestMode() { | 116 void EnableRendererLayoutTestMode() { |
112 RenderThreadImpl::current()->set_layout_test_mode(true); | 117 RenderThreadImpl::current()->set_layout_test_mode(true); |
113 } | 118 } |
114 | 119 |
115 void EnableBrowserLayoutTestMode() { | 120 void EnableBrowserLayoutTestMode() { |
116 #if defined(OS_MACOSX) | 121 #if defined(OS_MACOSX) |
117 ImageTransportSurface::SetAllowOSMesaForTesting(true); | 122 ImageTransportSurface::SetAllowOSMesaForTesting(true); |
118 PopupMenuHelper::DontShowPopupMenuForTesting(); | 123 PopupMenuHelper::DontShowPopupMenuForTesting(); |
119 #endif | 124 #endif |
120 RenderWidgetHostImpl::DisableResizeAckCheckForTesting(); | 125 RenderWidgetHostImpl::DisableResizeAckCheckForTesting(); |
(...skipping 174 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
295 result.append( | 300 result.append( |
296 DumpHistoryItem(entry->root_history_node(), | 301 DumpHistoryItem(entry->root_history_node(), |
297 8, | 302 8, |
298 index == current_index)); | 303 index == current_index)); |
299 } | 304 } |
300 result.append("===============================================\n"); | 305 result.append("===============================================\n"); |
301 return result; | 306 return result; |
302 } | 307 } |
303 | 308 |
304 } // namespace content | 309 } // namespace content |
OLD | NEW |