@Override protected void initTarget() { super.initTarget(); if (labelAlign != null && target != null) { target.addStyleName("x-form-label-" + labelAlign.name().toLowerCase()); } }
@Override public void setContainer(Container<?> ct) { if (labelAlign != null && target != null) { target.removeStyleName("x-form-label-" + labelAlign.name().toLowerCase()); } super.setContainer(ct); }
/** * Sets the label alignment. * * @param labelAlign the label align */ public void setLabelAlign(LabelAlign labelAlign) { if (this.labelAlign != labelAlign) { if (this.labelAlign != null && target != null) { target.removeStyleName("x-form-label-" + this.labelAlign.name().toLowerCase()); } this.labelAlign = labelAlign; if (labelAlign != null && target != null) { target.addStyleName("x-form-label-" + labelAlign.name().toLowerCase()); } } }