]> source.dussan.org Git - vaadin-framework.git/commitdiff
fixes #2415
authorMatti Tahvonen <matti.tahvonen@itmill.com>
Wed, 7 Jan 2009 10:05:00 +0000 (10:05 +0000)
committerMatti Tahvonen <matti.tahvonen@itmill.com>
Wed, 7 Jan 2009 10:05:00 +0000 (10:05 +0000)
svn changeset:6427/svn branch:trunk

WebContent/ITMILL/themes/default/progressindicator/progressindicator.css
WebContent/ITMILL/themes/default/styles.css
WebContent/ITMILL/themes/tests-tickets/styles.css
src/com/itmill/toolkit/terminal/gwt/client/ui/IProgressIndicator.java
src/com/itmill/toolkit/tests/tickets/Ticket2415.java

index ff53ff33b43d8d2fa43f144ae0d4241f76e0a13b..360a17db0757746e80843886fa5d39d1a1c03d32 100644 (file)
        width: 16px;
        overflow: hidden; /* for IE6 */
 }
-.i-progressindicator-disabled-indeterminate {
+
+/* Hide obsolete elements in indeterminate mode */
+.i-progressindicator-indeterminate .i-progressindicator-wrapper,
+.i-progressindicator-indeterminate .i-progressindicator-indicator,
+.i-progressindicator-indeterminate-disabled .i-progressindicator-wrapper,
+.i-progressindicator-indeterminate-disabled .i-progressindicator-indicator {
+       display: none;
+}
+
+.i-progressindicator-indeterminate-disabled {
        background: #dfe2e4 url(../common/img/blank.gif);
        height: 16px;
        width: 16px;
index b7bb7e658e01a4acc6dd468955ab84a8814cc42a..cb20c81a5cf6ff79fa0457be34581662614dc86e 100644 (file)
@@ -1190,7 +1190,16 @@ input.i-modified,
        width: 16px;
        overflow: hidden; /* for IE6 */
 }
-.i-progressindicator-disabled-indeterminate {
+
+/* Hide obsolete elements in indeterminate mode */
+.i-progressindicator-indeterminate .i-progressindicator-wrapper,
+.i-progressindicator-indeterminate .i-progressindicator-indicator,
+.i-progressindicator-indeterminate-disabled .i-progressindicator-wrapper,
+.i-progressindicator-indeterminate-disabled .i-progressindicator-indicator {
+       display: none;
+}
+
+.i-progressindicator-indeterminate-disabled {
        background: #dfe2e4 url(common/img/blank.gif);
        height: 16px;
        width: 16px;
index f03a28a1c2263c62ad59cf4325bb5eb690437e13..12c41e01fcd0f7eb88fcf35f466fa94e2877b1d5 100644 (file)
@@ -1253,4 +1253,12 @@ padding:2px;
   background: none !important;
   border: none !important;
   color: #222222 !important;   
+}
+
+.dispnone {
+       display:none;
+}
+
+.redborder {
+       border: 1px solid red;
 }
\ No newline at end of file
index 0567ec4012f2db3dee7486dc8e0c5039cb459c18..ebd7adcd27979867000eb8cede2503420758679c 100644 (file)
@@ -45,15 +45,12 @@ public class IProgressIndicator extends Widget implements Paintable {
 
         indeterminate = uidl.getBooleanAttribute("indeterminate");
 
-        String style = CLASSNAME;
-        if (uidl.getBooleanAttribute("disabled")) {
-            style += "-disabled";
-        }
-
         if (indeterminate) {
-            this.setStyleName(style + "-indeterminate");
+            String basename = CLASSNAME + "-indeterminate";
+            IProgressIndicator.setStyleName(getElement(), basename, true);
+            IProgressIndicator.setStyleName(getElement(), basename
+                    + "-disabled", uidl.getBooleanAttribute("disabled"));
         } else {
-            setStyleName(style);
             try {
                 final float f = Float.parseFloat(uidl
                         .getStringAttribute("state"));
index 7102b0cbc3a5aa700a6ca6f8e00c042bf5c42aff..b90cf88db216287c76cb2289656145a5bbf66533 100644 (file)
@@ -24,6 +24,17 @@ public class Ticket2415 extends Application {
             }
         });
 
+        final TextField tf2 = new TextField("Try to change me");
+        main.addComponent(tf2);
+
+        tf2.setImmediate(true);
+        tf2.addListener(new Property.ValueChangeListener() {
+
+            public void valueChange(ValueChangeEvent event) {
+                main.showNotification("New value = " + tf2);
+            }
+        });
+
     }
 
 }