Index: content/browser/gpu/compositor_util.cc |
diff --git a/content/browser/gpu/compositor_util.cc b/content/browser/gpu/compositor_util.cc |
index a9c3318c86b611e63b712756df9046a5c960d565..673e3cea098661bd358af49d6ab9910fbd1c9351 100644 |
--- a/content/browser/gpu/compositor_util.cc |
+++ b/content/browser/gpu/compositor_util.cc |
@@ -156,6 +156,22 @@ const GpuFeatureInfo GetGpuFeatureInfo(size_t index, bool* eof) { |
} // namespace |
+bool IsPinchVirtualViewportEnabled() { |
+ const CommandLine& command_line = *CommandLine::ForCurrentProcess(); |
+ |
+ // Command line switches take precedence over platform default. |
+ if (command_line.HasSwitch(cc::switches::kDisablePinchVirtualViewport)) |
+ return false; |
+ if (command_line.HasSwitch(cc::switches::kEnablePinchVirtualViewport)) |
+ return true; |
+ |
+#if defined(OS_CHROMEOS) |
+ return true; |
+#else |
+ return false; |
+#endif |
+} |
+ |
bool IsThreadedCompositingEnabled() { |
const CommandLine& command_line = *CommandLine::ForCurrentProcess(); |