]> source.dussan.org Git - vaadin-framework.git/commitdiff
Define .v-has-width/height instead of v-undefined-width/height (#8313)
authorLeif Åstrand <leif@vaadin.com>
Mon, 5 Mar 2012 11:20:41 +0000 (13:20 +0200)
committerLeif Åstrand <leif@vaadin.com>
Mon, 5 Mar 2012 11:21:36 +0000 (13:21 +0200)
WebContent/VAADIN/themes/base/csslayout/csslayout.css
WebContent/VAADIN/themes/reindeer/datefield/datefield.css
src/com/vaadin/terminal/gwt/client/ui/AbstractComponentConnector.java

index ec0ccc1f8447393e19e714e473cbf0b0eaddcbf4..1a4cb10a7750f9e0193d4636e87bded7562d005d 100644 (file)
@@ -2,16 +2,16 @@
        overflow: hidden;
 }
 .v-csslayout-margin, .v-csslayout-container {
-       height: 100%;
-       width: 100%;
        box-sizing: border-box;
        -moz-box-sizing: border-box;
 }
-.v-undefined-width > .v-csslayout-margin, .v-undefined-width > .v-csslayout-margin > .v-csslayout-container {
-       width: auto;
+.v-has-width > .v-csslayout-margin,
+.v-has-width > .v-csslayout-margin > .v-csslayout-container {
+       width: 100%;
 }
-.v-undefined-height > .v-csslayout-margin, .v-undefined-height > .v-csslayout-margin > .v-csslayout-container {
-       height: auto;
+.v-has-height > .v-csslayout-margin,
+.v-has-height > .v-csslayout-margin > .v-csslayout-container {
+       height: 100%;
 }
 .v-csslayout-margin-top {
        padding-top: 12px;      
index 9ca90fd7333054617ddd07bb2c2115e3d6c7595d..da50d1cbbe899e4c8c78b4cdbc5bc432b8496467 100644 (file)
@@ -225,22 +225,19 @@ td.v-datefield-calendarpanel-nextyear {
 .v-op .v-datefield-popup {
        background: rgba(255,255,255,.95);
 }
-.v-datefield-textfield {
+.v-has-width > input.v-datefield-textfield {
        width: 100%;
 }
-.v-undefined-width > .v-datefield-textfield {
-       width: auto;
-}
-.v-datefield-year.v-undefined-width > .v-datefield-textfield {
+.v-datefield-year > .v-datefield-textfield {
        width: 4.5em;
 }
-.v-datefield-month.v-undefined-width > .v-datefield-textfield {
+.v-datefield-month > .v-datefield-textfield {
        width: 5.5em;
 }
-.v-datefield-day.v-undefined-width > .v-datefield-textfield {
+.v-datefield-day > .v-datefield-textfield {
        width: 6em;
 }
-.v-datefield-full.v-undefined-width  >.v-datefield-textfield {
+.v-datefield-full >.v-datefield-textfield {
        width: 12.5em;
 }
 .v-datefield-popupcalendar input.v-datefield-textfield {
index f6419afecd7baa82133f45a71ef428aee5f92f85..f648428c6a992d6a0f17b4832d15c215ff7762bb 100644 (file)
@@ -249,8 +249,8 @@ public abstract class AbstractComponentConnector extends AbstractConnector
         // Set defined sizes
         Widget component = getWidget();
 
-        component.setStyleName("v-undefined-width", isUndefinedWidth());
-        component.setStyleName("v-undefined-height", isUndefinedHeight());
+        component.setStyleName("v-has-width", !isUndefinedWidth());
+        component.setStyleName("v-has-height", !isUndefinedHeight());
 
         component.setHeight(h);
         component.setWidth(w);