about:flags options for accelerated compositing and accelerated animation.


Review URL: http://codereview.chromium.org/9706093

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@127137 0039d316-1c4b-4281-b951-d872f2087c98
diff --git a/chrome/app/generated_resources.grd b/chrome/app/generated_resources.grd
index 8a58e052..0b47ad58 100644
--- a/chrome/app/generated_resources.grd
+++ b/chrome/app/generated_resources.grd
@@ -4908,6 +4908,18 @@
         Disables synchronization with the display's vertical refresh rate when GPU rendering. This allows frame rates to exceed
         60 hertz. While useful for benchmarking purposes, this also results in visual tearing during rapid screen updates.
       </message>
+      <message name="IDS_FLAGS_ENABLE_THREADED_COMPOSITING_NAME" desc="Name of the 'Enabled threaded compositing' lab.">
+        Enable threaded compositing
+      </message>
+      <message name="IDS_FLAGS_ENABLE_THREADED_COMPOSITING_DESCRIPTION" desc="Description of the 'Enable threaded compositing' lab.">
+        Uses a secondary thread to perform web page compositing. This allows smooth scrolling, even when the main thread is unresponsive.
+      </message>
+      <message name="IDS_FLAGS_ENABLE_THREADED_ANIMATION_NAME" desc="Name of the 'Enabled threaded animation' lab.">
+        Enable threaded animation
+      </message>
+      <message name="IDS_FLAGS_ENABLE_THREADED_ANIMATION_DESCRIPTION" desc="Description of the 'Enable threaded animation' lab.">
+        Uses a secondary thread to execute CSS animations. This allows smoother animations, even when the main thread is unresponsive.
+      </message>
       <message name="IDS_FLAGS_WEBGL_NAME" desc="Name of the 'WebGL' lab.">
         WebGL
       </message>
diff --git a/chrome/browser/about_flags.cc b/chrome/browser/about_flags.cc
index 30397b6..45ba822 100644
--- a/chrome/browser/about_flags.cc
+++ b/chrome/browser/about_flags.cc
@@ -180,6 +180,20 @@
     SINGLE_VALUE_TYPE(switches::kForceCompositingMode)
   },
   {
+    "enable-threaded-compositing",
+    IDS_FLAGS_ENABLE_THREADED_COMPOSITING_NAME,
+    IDS_FLAGS_ENABLE_THREADED_COMPOSITING_DESCRIPTION,
+    kOsAll,
+    SINGLE_VALUE_TYPE(switches::kEnableThreadedCompositing)
+  },
+  {
+    "enable-threaded-animation",
+    IDS_FLAGS_ENABLE_THREADED_ANIMATION_NAME,
+    IDS_FLAGS_ENABLE_THREADED_ANIMATION_DESCRIPTION,
+    kOsAll,
+    SINGLE_VALUE_TYPE(switches::kEnableThreadedAnimation)
+  },
+  {
     "composited-layer-borders",
     IDS_FLAGS_COMPOSITED_LAYER_BORDERS,
     IDS_FLAGS_COMPOSITED_LAYER_BORDERS_DESCRIPTION,