From 2d09c389714a7419e974772080ed448a4fb27181 Mon Sep 17 00:00:00 2001 From: John Ahlroos Date: Wed, 26 Sep 2012 09:47:35 +0300 Subject: [PATCH] Minor change to how the primary stylename gets applied to the widgets #9724 --- .../com/vaadin/client/ui/AbstractComponentConnector.java | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/client/src/com/vaadin/client/ui/AbstractComponentConnector.java b/client/src/com/vaadin/client/ui/AbstractComponentConnector.java index 339bcc9a46..26133204e2 100644 --- a/client/src/com/vaadin/client/ui/AbstractComponentConnector.java +++ b/client/src/com/vaadin/client/ui/AbstractComponentConnector.java @@ -72,8 +72,6 @@ public abstract class AbstractComponentConnector extends AbstractConnector getConnection().getVTooltip().connectHandlersToWidget(getWidget()); - // Set the core 'v' style name for the widget - getWidget().setStyleName(StyleConstants.UI_WIDGET, true); } /** @@ -275,11 +273,14 @@ public abstract class AbstractComponentConnector extends AbstractConnector if (state.primaryStyleName != null) { /* * We overwrite the widgets primary stylename if state defines a - * primary stylename + * primary stylename. Clears all previous stylenames. */ - getWidget().setStylePrimaryName(state.primaryStyleName); + getWidget().setStyleName(state.primaryStyleName); } + // Set the core 'v' style name for the widget + setWidgetStyleName(StyleConstants.UI_WIDGET, true); + // should be in AbstractFieldConnector ? // add / remove read-only style name setWidgetStyleName("v-readonly", isReadOnly()); -- 2.39.5