From 0191f9fdefca58494e17502de447cd92bd6e8cf5 Mon Sep 17 00:00:00 2001 From: Matti Tahvonen Date: Mon, 10 Nov 2008 13:56:11 +0000 Subject: [PATCH] formlayout now reservers space for error indicator even though nothing is visible svn changeset:5848/svn branch:trunk --- .../ITMILL/themes/default/formlayout/formlayout.css | 10 ++++++++++ WebContent/ITMILL/themes/default/styles.css | 9 +++++++++ .../toolkit/terminal/gwt/client/ui/IFormLayout.java | 3 ++- 3 files changed, 21 insertions(+), 1 deletion(-) diff --git a/WebContent/ITMILL/themes/default/formlayout/formlayout.css b/WebContent/ITMILL/themes/default/formlayout/formlayout.css index b795e5c8ea..da6f864210 100644 --- a/WebContent/ITMILL/themes/default/formlayout/formlayout.css +++ b/WebContent/ITMILL/themes/default/formlayout/formlayout.css @@ -6,6 +6,16 @@ } .i-formlayout-captioncell { text-align:right; + white-space: nowrap; +} + +.i-formlayout-contentcell { + width:100%; +} + +.i-formlayout-error-indicator { + /* fix width so layout is not jumpy when error disapear */ + width: 12px; } .i-formlayout-spacing .i-formlayout-row .i-formlayout-captioncell, diff --git a/WebContent/ITMILL/themes/default/styles.css b/WebContent/ITMILL/themes/default/styles.css index 0ea9b65850..45a1f86231 100644 --- a/WebContent/ITMILL/themes/default/styles.css +++ b/WebContent/ITMILL/themes/default/styles.css @@ -655,6 +655,15 @@ input.i-modified, } .i-formlayout-captioncell { text-align:right; + white-space: nowrap; +} + +.i-formlayout-contentcell { + width:100%; +} + +.i-formlayout-error-indicator { + width: 12px; } .i-formlayout-spacing .i-formlayout-row .i-formlayout-captioncell, diff --git a/src/com/itmill/toolkit/terminal/gwt/client/ui/IFormLayout.java b/src/com/itmill/toolkit/terminal/gwt/client/ui/IFormLayout.java index f856f4a23c..6a7f32f777 100644 --- a/src/com/itmill/toolkit/terminal/gwt/client/ui/IFormLayout.java +++ b/src/com/itmill/toolkit/terminal/gwt/client/ui/IFormLayout.java @@ -270,7 +270,8 @@ public class IFormLayout extends FlexTable implements Container { } private class ErrorFlag extends HTML { - private static final String CLASSNAME = ".i-form-layout-error-indicator"; + private static final String CLASSNAME = IFormLayout.CLASSNAME + + "-error-indicator"; Element errorIndicatorElement; private Paintable owner; -- 2.39.5