diff options
7 files changed, 26 insertions, 19 deletions
diff --git a/WebContent/VAADIN/themes/base/boxlayout/boxlayout.scss b/WebContent/VAADIN/themes/base/boxlayout/boxlayout.scss index ef0f021a0a..1ece1e08ca 100644 --- a/WebContent/VAADIN/themes/base/boxlayout/boxlayout.scss +++ b/WebContent/VAADIN/themes/base/boxlayout/boxlayout.scss @@ -22,7 +22,7 @@ TODO display: inline-block; } -div.v-boxlayout.v-horizontal.v { +div.v-boxlayout.v-horizontal.v-widget { white-space: nowrap; } @@ -91,17 +91,17 @@ div.v-boxlayout.v-horizontal.v { } .v-align-middle > .v, -.v-align-bottom > .v { +.v-align-bottom > .v-widget { display: inline-block; } .v-align-middle, -.v-align-middle > .v { +.v-align-middle > .v-widget { vertical-align: middle; } .v-align-bottom, -.v-align-bottom > .v { +.v-align-bottom > .v-widget { vertical-align: bottom; } @@ -109,7 +109,7 @@ div.v-boxlayout.v-horizontal.v { text-align: center; } -.v-align-center > .v { +.v-align-center > .v-widget { margin-left: auto; margin-right: auto; } @@ -118,7 +118,7 @@ div.v-boxlayout.v-horizontal.v { text-align: right; } -.v-align-right > .v { +.v-align-right > .v-widget { margin-left: auto; } @@ -151,16 +151,16 @@ div.v-boxlayout.v-horizontal.v { } .v-caption-on-left > .v, -.v-caption-on-right > .v { +.v-caption-on-right > .v-widget { display: inline-block; vertical-align: middle; } -.v-has-caption.v-has-width > .v { +.v-has-caption.v-has-width > .v-widget { width: 100% !important; } -.v-has-caption.v-has-height > .v { +.v-has-caption.v-has-height > .v-widget { height: 100% !important; } diff --git a/WebContent/VAADIN/themes/base/paintable/paintable.scss b/WebContent/VAADIN/themes/base/paintable/paintable.scss index 92f30604ff..2dab62f558 100644 --- a/WebContent/VAADIN/themes/base/paintable/paintable.scss +++ b/WebContent/VAADIN/themes/base/paintable/paintable.scss @@ -1,6 +1,6 @@ @mixin base-paintable { -.v { +.v-widget { -webkit-box-sizing: border-box; -moz-box-sizing: border-box; box-sizing: border-box; diff --git a/WebContent/VAADIN/themes/chameleon/components/textfield/textfield.scss b/WebContent/VAADIN/themes/chameleon/components/textfield/textfield.scss index f8f3788c9e..335b9d9451 100644 --- a/WebContent/VAADIN/themes/chameleon/components/textfield/textfield.scss +++ b/WebContent/VAADIN/themes/chameleon/components/textfield/textfield.scss @@ -27,7 +27,7 @@ input.v-textfield[type="text"] { height: 1.2em; } -input.v-connector.v-textfield[type="text"], +input.v-widget.v-textfield[type="text"], .v-filterselect { height: 1.6em; } diff --git a/WebContent/VAADIN/themes/reindeer/textfield/textfield.scss b/WebContent/VAADIN/themes/reindeer/textfield/textfield.scss index 8db2dda567..7350f699f9 100644 --- a/WebContent/VAADIN/themes/reindeer/textfield/textfield.scss +++ b/WebContent/VAADIN/themes/reindeer/textfield/textfield.scss @@ -37,8 +37,8 @@ .v-window textarea.v-textarea { padding: 3px 3px 4px; } -.v-app input.v-textfield.v-connector, -.v-window input.v-textfield.v-connector { +.v-app input.v-textfield.v-widget, +.v-window input.v-textfield.v-widget { height: 24px; } .v-app .v-textfield-focus, @@ -68,8 +68,8 @@ textarea.v-textarea-prompt { .v-app textarea.v-textarea-small { font-size: 11px; } -.v-app .v-table input.v-textfield.v-connector, -.v-window .v-table input.v-textfield.v-connector { +.v-app .v-table input.v-textfield.v-widget, +.v-window .v-table input.v-textfield.v-widget { padding: 1px 2px; height: auto; line-height: normal; diff --git a/client/src/com/vaadin/terminal/gwt/client/ui/AbstractComponentConnector.java b/client/src/com/vaadin/terminal/gwt/client/ui/AbstractComponentConnector.java index 14d7f4007e..9ccf1deb7c 100644 --- a/client/src/com/vaadin/terminal/gwt/client/ui/AbstractComponentConnector.java +++ b/client/src/com/vaadin/terminal/gwt/client/ui/AbstractComponentConnector.java @@ -42,9 +42,10 @@ import com.vaadin.terminal.gwt.client.metadata.Type; import com.vaadin.terminal.gwt.client.metadata.TypeData; import com.vaadin.terminal.gwt.client.ui.UI.UIConnector; import com.vaadin.terminal.gwt.client.ui.datefield.PopupDateFieldConnector; +import com.vaadin.ui.themes.BaseTheme; public abstract class AbstractComponentConnector extends AbstractConnector - implements ComponentConnector { +implements ComponentConnector { private Widget widget; @@ -70,7 +71,7 @@ public abstract class AbstractComponentConnector extends AbstractConnector getConnection().getVTooltip().connectHandlersToWidget(getWidget()); // Set the core 'v' style name for the widget - getWidget().setStyleName("v", true); + getWidget().setStyleName(BaseTheme.UI_WIDGET, true); } /** @@ -90,7 +91,7 @@ public abstract class AbstractComponentConnector extends AbstractConnector "There is no information about the widget for " + Util.getSimpleName(this) + ". Did you remember to compile the right widgetset?", - e); + e); } } diff --git a/client/src/com/vaadin/terminal/gwt/client/ui/orderedlayout/VBoxLayout.java b/client/src/com/vaadin/terminal/gwt/client/ui/orderedlayout/VBoxLayout.java index c8fff17cba..cd6a5f0d51 100644 --- a/client/src/com/vaadin/terminal/gwt/client/ui/orderedlayout/VBoxLayout.java +++ b/client/src/com/vaadin/terminal/gwt/client/ui/orderedlayout/VBoxLayout.java @@ -23,6 +23,7 @@ import com.vaadin.shared.ui.AlignmentInfo; import com.vaadin.shared.ui.MarginInfo; import com.vaadin.terminal.gwt.client.ComponentConnector; import com.vaadin.terminal.gwt.client.LayoutManager; +import com.vaadin.ui.themes.BaseTheme; public class VBoxLayout extends FlowPanel { @@ -254,7 +255,7 @@ public class VBoxLayout extends FlowPanel { if (caption == null) { caption = DOM.createDiv(); captionWrap = DOM.createDiv(); - captionWrap.addClassName("v"); + captionWrap.addClassName(BaseTheme.UI_WIDGET); captionWrap.addClassName("v-has-caption"); getElement().appendChild(captionWrap); captionWrap.appendChild(getWidget().getElement()); diff --git a/server/src/com/vaadin/ui/themes/BaseTheme.java b/server/src/com/vaadin/ui/themes/BaseTheme.java index 9e95627eec..ea5ba54f53 100644 --- a/server/src/com/vaadin/ui/themes/BaseTheme.java +++ b/server/src/com/vaadin/ui/themes/BaseTheme.java @@ -56,4 +56,9 @@ public class BaseTheme { */ public static final String CLIP = "v-clip"; + /** + * Added to all UI components + */ + public static final String UI_WIDGET = "v-widget"; + }
\ No newline at end of file |