Allow applications to disable clippy the flash movie

Some users may wish to disable flash entirely, as it does slow down
the user interface, and may offer only very little, if any benefit,
to the user.

Signed-off-by: Shawn O. Pearce <sop@google.com>
diff --git a/src/main/java/com/google/gwtexpui/clippy/client/CopyableLabel.java b/src/main/java/com/google/gwtexpui/clippy/client/CopyableLabel.java
index 869f63f..e10f683 100644
--- a/src/main/java/com/google/gwtexpui/clippy/client/CopyableLabel.java
+++ b/src/main/java/com/google/gwtexpui/clippy/client/CopyableLabel.java
@@ -50,6 +50,15 @@
   private static final int SWF_WIDTH = 110;
   private static final int SWF_HEIGHT = 14;
   private static String swfUrl;
+  private static boolean flashEnabled = true;
+
+  public static boolean isFlashEnabled() {
+    return flashEnabled;
+  }
+
+  public static void setFlashEnabled(final boolean on) {
+    flashEnabled = on;
+  }
 
   private static String swfUrl() {
     if (swfUrl == null) {
@@ -101,7 +110,7 @@
   }
 
   private void embedMovie() {
-    if (UserAgent.hasFlash) {
+    if (flashEnabled && UserAgent.hasFlash) {
       final String flashVars = "text=" + URL.encodeComponent(getText());
       final SafeHtmlBuilder h = new SafeHtmlBuilder();