]> source.dussan.org Git - vaadin-framework.git/commitdiff
Renamed .v-boxlayout selector to .v-layout and applied the .v-layout
authorJohn Ahlroos <john@vaadin.com>
Thu, 6 Sep 2012 13:27:04 +0000 (16:27 +0300)
committerJohn Ahlroos <john@vaadin.com>
Thu, 6 Sep 2012 13:27:04 +0000 (16:27 +0300)
selector to all layouts

18 files changed:
WebContent/VAADIN/themes/base/base.scss
WebContent/VAADIN/themes/base/boxlayout/boxlayout.css [deleted file]
WebContent/VAADIN/themes/base/boxlayout/boxlayout.scss [deleted file]
WebContent/VAADIN/themes/base/layout/layout.scss [new file with mode: 0644]
WebContent/VAADIN/themes/base/styles.scss
WebContent/VAADIN/themes/reindeer/layouts/layouts.scss
WebContent/VAADIN/themes/runo/orderedlayout/orderedlayout.scss
WebContent/VAADIN/themes/tests-components/styles.css
client/src/com/vaadin/client/ui/absolutelayout/VAbsoluteLayout.java
client/src/com/vaadin/client/ui/csslayout/VCssLayout.java
client/src/com/vaadin/client/ui/customlayout/VCustomLayout.java
client/src/com/vaadin/client/ui/formlayout/VFormLayout.java
client/src/com/vaadin/client/ui/gridlayout/VGridLayout.java
client/src/com/vaadin/client/ui/orderedlayout/VHorizontalLayout.java
client/src/com/vaadin/client/ui/orderedlayout/VOrderedLayout.java
client/src/com/vaadin/client/ui/orderedlayout/VVerticalLayout.java
client/src/com/vaadin/client/ui/splitpanel/VAbstractSplitPanel.java
server/src/com/vaadin/ui/themes/BaseTheme.java

index efe6e0cd052d0005043de148aff3970f483107d3..915da192260c7f56df75d479ffdf03e29a9c2fc4 100644 (file)
@@ -1,7 +1,7 @@
 @import "absolutelayout/absolutelayout.scss";
 @import "accordion/accordion.scss";
 @import "button/button.scss";
-@import "boxlayout/boxlayout.scss";
+@import "layout/layout.scss";
 @import "caption/caption.scss";
 @import "common/common.scss";
 @import "csslayout/csslayout.scss";
diff --git a/WebContent/VAADIN/themes/base/boxlayout/boxlayout.css b/WebContent/VAADIN/themes/base/boxlayout/boxlayout.css
deleted file mode 100644 (file)
index f899e8f..0000000
+++ /dev/null
@@ -1,167 +0,0 @@
-/*
-TODO
-- separate styles to proper places
-- decide a good class name structure for core layouts (e.g. 'v-layout', 'v-vertical', 'v-grid' etc.)
-- use !important in carefully selected places to prevent accidental layout breakage by custom theming (e.g. alignments should be forced)
-
-*/
-
-.v-boxlayout.v-margin-top              {padding-top:           12px;}
-.v-boxlayout.v-margin-right    {padding-right:         12px;}
-.v-boxlayout.v-margin-bottom   {padding-bottom:        12px;}
-.v-boxlayout.v-margin-left             {padding-left:          12px;}
-
-.v-spacing {
-       width: 6px;
-       height: 6px;
-}
-
-.v-boxlayout {
-       display: inline-block;
-}
-
-div.v-boxlayout.v-horizontal.v {
-       white-space: nowrap;
-}
-
-.v-boxlayout > .v-expand {
-       -webkit-box-sizing: border-box;
-       -moz-box-sizing: border-box;
-       box-sizing: border-box;
-       width: 100%;
-       height: 100%;
-}
-
-.v-slot,
-.v-spacing {
-       display: inline-block;
-       white-space: normal;
-       vertical-align: top;
-}
-
-/* Clear any floats inside the slot, to prevent unwanted collapsing */
-.v-vertical > .v-slot:after {
-       content: "";
-       display: inline-block;
-       clear: both;
-       width: 0;
-       height: 0;
-       overflow: hidden;
-}
-
-.v-vertical > .v-slot,
-.v-vertical > .v-expand > .v-slot {
-       display: block;
-       clear: both;
-}
-
-.v-horizontal > .v-slot,
-.v-horizontal > .v-expand > .v-slot {
-       height: 100%;
-}
-
-.v-vertical > .v-spacing,
-.v-vertical > .v-expand > .v-spacing {
-       width: 0;
-       display: block;
-       clear: both;
-}
-
-.v-horizontal > .v-spacing,
-.v-horizontal > .v-expand > .v-spacing {
-       height: 0;
-}
-
-.v-align-middle:before,
-.v-align-bottom:before,
-.v-expand > .v-align-middle:before,
-.v-expand > .v-align-bottom:before {
-       content: "";
-       display: inline-block;
-       height: 100%;
-       vertical-align: middle;
-       width: 0;
-}
-
-.v-align-middle,
-.v-align-bottom {
-       white-space: nowrap;
-}
-
-.v-align-middle > .v,
-.v-align-bottom > .v {
-       display: inline-block;
-}
-
-.v-align-middle,
-.v-align-middle > .v {
-       vertical-align: middle;
-}
-
-.v-align-bottom,
-.v-align-bottom > .v {
-       vertical-align: bottom;
-}
-
-.v-align-center {
-       text-align: center;
-}
-
-.v-align-center > .v {
-       margin-left: auto;
-       margin-right: auto;
-}
-
-.v-align-right {
-       text-align: right;
-}
-
-.v-align-right > .v {
-       margin-left: auto;
-}
-
-.v-has-caption,
-.v-has-caption > .v-caption {
-       display: inline-block; /* Force natural width to zero */
-}
-
-.v-caption {
-       overflow: visible;
-       vertical-align: middle;
-}
-
-.v-caption-on-left,
-.v-caption-on-right {
-       white-space: nowrap;
-}
-
-.v-caption-on-top > .v-caption,
-.v-caption-on-bottom > .v-caption {
-       display: block;
-}
-
-.v-caption-on-left > .v-caption {
-       padding-right: .5em;
-}
-
-.v-caption-on-right > .v-caption {
-       padding-left: .5em;
-}
-
-.v-caption-on-left > .v,
-.v-caption-on-right > .v {
-       display: inline-block;
-       vertical-align: middle;
-}
-
-.v-has-caption.v-has-width > .v {
-       width: 100% !important;
-}
-
-.v-has-caption.v-has-height > .v {
-       height: 100% !important;
-}
-
-.v-errorindicator {
-       vertical-align: middle;
-}
\ No newline at end of file
diff --git a/WebContent/VAADIN/themes/base/boxlayout/boxlayout.scss b/WebContent/VAADIN/themes/base/boxlayout/boxlayout.scss
deleted file mode 100644 (file)
index 92e0eb4..0000000
+++ /dev/null
@@ -1,171 +0,0 @@
-/*
-TODO
-- separate styles to proper places
-- decide a good class name structure for core layouts (e.g. 'v-layout', 'v-vertical', 'v-grid' etc.)
-- use !important in carefully selected places to prevent accidental layout breakage by custom theming (e.g. alignments should be forced)
-
-*/
-
-@mixin base-boxlayout {
-
-.v-boxlayout.v-margin-top              {padding-top:           12px;}
-.v-boxlayout.v-margin-right    {padding-right:         12px;}
-.v-boxlayout.v-margin-bottom   {padding-bottom:        12px;}
-.v-boxlayout.v-margin-left             {padding-left:          12px;}
-
-.v-spacing {
-       width: 6px;
-       height: 6px;
-}
-
-.v-boxlayout {
-       display: inline-block;
-}
-
-div.v-boxlayout.v-horizontal.v-widget {
-       white-space: nowrap;
-}
-
-.v-boxlayout > .v-expand {
-       -webkit-box-sizing: border-box;
-       -moz-box-sizing: border-box;
-       box-sizing: border-box;
-       width: 100%;
-       height: 100%;
-}
-
-.v-slot,
-.v-spacing {
-       display: inline-block;
-       white-space: normal;
-       vertical-align: top;
-}
-
-/* Clear any floats inside the slot, to prevent unwanted collapsing */
-.v-vertical > .v-slot:after {
-       content: "";
-       display: inline-block;
-       clear: both;
-       width: 0;
-       height: 0;
-       overflow: hidden;
-}
-
-.v-vertical > .v-slot,
-.v-vertical > .v-expand > .v-slot {
-       display: block;
-       clear: both;
-}
-
-.v-horizontal > .v-slot,
-.v-horizontal > .v-expand > .v-slot {
-       height: 100%;
-}
-
-.v-vertical > .v-spacing,
-.v-vertical > .v-expand > .v-spacing {
-       width: 0;
-       display: block;
-       clear: both;
-}
-
-.v-horizontal > .v-spacing,
-.v-horizontal > .v-expand > .v-spacing {
-       height: 0;
-}
-
-.v-align-middle:before,
-.v-align-bottom:before,
-.v-expand > .v-align-middle:before,
-.v-expand > .v-align-bottom:before {
-       content: "";
-       display: inline-block;
-       height: 100%;
-       vertical-align: middle;
-       width: 0;
-}
-
-.v-align-middle,
-.v-align-bottom {
-       white-space: nowrap;
-}
-
-.v-align-middle > .v,
-.v-align-bottom > .v-widget {
-       display: inline-block;
-}
-
-.v-align-middle,
-.v-align-middle > .v-widget {
-       vertical-align: middle;
-}
-
-.v-align-bottom,
-.v-align-bottom > .v-widget {
-       vertical-align: bottom;
-}
-
-.v-align-center {
-       text-align: center;
-}
-
-.v-align-center > .v-widget {
-       margin-left: auto;
-       margin-right: auto;
-}
-
-.v-align-right {
-       text-align: right;
-}
-
-.v-align-right > .v-widget {
-       margin-left: auto;
-}
-
-.v-has-caption,
-.v-has-caption > .v-caption {
-       display: inline-block; /* Force natural width to zero */
-}
-
-.v-caption {
-       overflow: visible;
-       vertical-align: middle;
-}
-
-.v-caption-on-left,
-.v-caption-on-right {
-       white-space: nowrap;
-}
-
-.v-caption-on-top > .v-caption,
-.v-caption-on-bottom > .v-caption {
-       display: block;
-}
-
-.v-caption-on-left > .v-caption {
-       padding-right: .5em;
-}
-
-.v-caption-on-right > .v-caption {
-       vertical-align:top;
-}
-
-.v-caption-on-left > .v,
-.v-caption-on-right > .v-widget {
-       display: inline-block;
-       vertical-align: middle;
-}
-
-.v-has-caption.v-has-width > .v-widget {
-       width: 100% !important;
-}
-
-.v-has-caption.v-has-height > .v-widget {
-       height: 100% !important;
-}
-
-.v-errorindicator {
-       vertical-align: middle;
-}
-
-}
\ No newline at end of file
diff --git a/WebContent/VAADIN/themes/base/layout/layout.scss b/WebContent/VAADIN/themes/base/layout/layout.scss
new file mode 100644 (file)
index 0000000..af49dd4
--- /dev/null
@@ -0,0 +1,188 @@
+/*
+TODO
+- separate styles to proper places
+- decide a good class name structure for core layouts (e.g. 'v-layout', 'v-vertical', 'v-grid' etc.)
+- use !important in carefully selected places to prevent accidental layout breakage by custom theming (e.g. alignments should be forced)
+
+*/
+
+@mixin base-layout {
+
+.v-vertical.v-margin-top,
+.v-horizontal.v-margin-top {
+       padding-top: 12px;
+}
+
+.v-vertical.v-margin-right,
+.v-horizontal.v-margin-right   {
+       padding-right:  12px;
+}
+
+.v-vertical.v-margin-bottom,
+.v-horizontal.v-margin-bottom {
+       padding-bottom: 12px;
+}
+
+.v-layout.v-vertical.v-margin-left,
+.v-layout.v-horizontal.v-margin-left {
+       padding-left: 12px;
+}
+
+.v-spacing {
+       width: 6px;
+       height: 6px;
+}
+
+.v-vertical,
+.v-horizontal {
+       display: inline-block;
+}
+
+div.v-layout.v-horizontal.v-widget {
+       white-space: nowrap;
+}
+
+.v-layout.v-vertical > .v-expand,
+.v-layout.v-horizontal > .v-expand {
+       -webkit-box-sizing: border-box;
+       -moz-box-sizing: border-box;
+       box-sizing: border-box;
+       width: 100%;
+       height: 100%;
+}
+
+.v-slot,
+.v-spacing {
+       display: inline-block;
+       white-space: normal;
+       vertical-align: top;
+}
+
+/* Clear any floats inside the slot, to prevent unwanted collapsing */
+.v-vertical > .v-slot:after {
+       content: "";
+       display: inline-block;
+       clear: both;
+       width: 0;
+       height: 0;
+       overflow: hidden;
+}
+
+.v-vertical > .v-slot,
+.v-vertical > .v-expand > .v-slot {
+       display: block;
+       clear: both;
+}
+
+.v-horizontal > .v-slot,
+.v-horizontal > .v-expand > .v-slot {
+       height: 100%;
+}
+
+.v-vertical > .v-spacing,
+.v-vertical > .v-expand > .v-spacing {
+       width: 0;
+       display: block;
+       clear: both;
+}
+
+.v-horizontal > .v-spacing,
+.v-horizontal > .v-expand > .v-spacing {
+       height: 0;
+}
+
+.v-align-middle:before,
+.v-align-bottom:before,
+.v-expand > .v-align-middle:before,
+.v-expand > .v-align-bottom:before {
+       content: "";
+       display: inline-block;
+       height: 100%;
+       vertical-align: middle;
+       width: 0;
+}
+
+.v-align-middle,
+.v-align-bottom {
+       white-space: nowrap;
+}
+
+.v-align-middle > .v,
+.v-align-bottom > .v-widget {
+       display: inline-block;
+}
+
+.v-align-middle,
+.v-align-middle > .v-widget {
+       vertical-align: middle;
+}
+
+.v-align-bottom,
+.v-align-bottom > .v-widget {
+       vertical-align: bottom;
+}
+
+.v-align-center {
+       text-align: center;
+}
+
+.v-align-center > .v-widget {
+       margin-left: auto;
+       margin-right: auto;
+}
+
+.v-align-right {
+       text-align: right;
+}
+
+.v-align-right > .v-widget {
+       margin-left: auto;
+}
+
+.v-has-caption,
+.v-has-caption > .v-caption {
+       display: inline-block; /* Force natural width to zero */
+}
+
+.v-caption {
+       overflow: visible;
+       vertical-align: middle;
+}
+
+.v-caption-on-left,
+.v-caption-on-right {
+       white-space: nowrap;
+}
+
+.v-caption-on-top > .v-caption,
+.v-caption-on-bottom > .v-caption {
+       display: block;
+}
+
+.v-caption-on-left > .v-caption {
+       padding-right: .5em;
+}
+
+.v-caption-on-right > .v-caption {
+       vertical-align:top;
+}
+
+.v-caption-on-left > .v,
+.v-caption-on-right > .v-widget {
+       display: inline-block;
+       vertical-align: middle;
+}
+
+.v-has-caption.v-has-width > .v-widget {
+       width: 100% !important;
+}
+
+.v-has-caption.v-has-height > .v-widget {
+       height: 100% !important;
+}
+
+.v-errorindicator {
+       vertical-align: middle;
+}
+
+}
\ No newline at end of file
index 7a650d081869a286152f694c4925f17ed5401339..ed37d3cc800fa6b8b156653b29ce72bed66458de 100644 (file)
@@ -15,7 +15,7 @@
 // here for now to preserve old semantics
 @include base-common;
 
-@include base-boxlayout;
+@include base-layout;
 @include base-csslayout;
 @include base-customcomponent;
 @include base-customlayout;
index e1bef65f1e442dd7f2f7d98079555dfb8dc0ab94..c0204ec041c18023814bce1b5d866737ee5adafd 100644 (file)
@@ -3,25 +3,25 @@
 .v-orderedlayout-margin-top,
 .v-horizontallayout-margin-top,
 .v-verticallayout-margin-top,
-.v-boxlayout.v-margin-top {
+.v-layout.v-margin-top {
        padding-top: 18px;
 }
 .v-orderedlayout-margin-right,
 .v-horizontallayout-margin-right,
 .v-verticallayout-margin-right,
-.v-boxlayout.v-margin-right {
+.v-layout.v-margin-right {
        padding-right: 18px;
 }
 .v-orderedlayout-margin-bottom,
 .v-horizontallayout-margin-bottom,
 .v-verticallayout-margin-bottom,
-.v-boxlayout.v-margin-bottom {
+.v-layout.v-margin-bottom {
        padding-bottom: 18px;
 }
 .v-orderedlayout-margin-left,
 .v-horizontallayout-margin-left,
 .v-verticallayout-margin-left,
-.v-boxlayout.v-margin-left {
+.v-layout.v-margin-left {
        padding-left: 18px;
 }
 .v-orderedlayout-spacing-on,
index 37ae0279b6d6ebade7aed79d9235d485a926847a..8799c7d8a61e0aa0787fac7a6bbd50b55d492030 100644 (file)
@@ -4,28 +4,28 @@
 .v-horizontallayout-margin-top,
 .v-verticallayout-margin-top,
 .v-csslayout-margin-top,
-.v-boxlayout.v-margin-top {
+.v-layout.v-margin-top {
        padding-top: 15px;
 }
 .v-orderedlayout-margin-right,
 .v-horizontallayout-margin-right,
 .v-verticallayout-margin-right,
 .v-csslayout-margin-right,
-.v-boxlayout.v-margin-right {
+.v-layout.v-margin-right {
        padding-right: 18px;
 }
 .v-orderedlayout-margin-bottom,
 .v-horizontallayout-margin-bottom,
 .v-verticallayout-margin-bottom,
 .v-csslayout-margin-bottom,
-.v-boxlayout.v-margin-bottom {
+.v-layout.v-margin-bottom {
        padding-bottom: 15px;
 }
 .v-orderedlayout-margin-left,
 .v-horizontallayout-margin-left,
 .v-verticallayout-margin-left,
 .v-csslayout-margin-left,
-.v-boxlayout.v-margin-left {
+.v-layout.v-margin-left {
        padding-left: 18px;
 }
 .v-orderedlayout-spacing-on,
index 45a96b6d161c2d76856dfd3c4382b6a5aa99a39d..2d54a4812403d43a56655db17dc6e9bd42f241ef 100644 (file)
        background: #f00;
 }
 
-.v-boxlayout.test {
+.v-layout.test {
        border: 1px solid #ddd;
 }
 
-.v-boxlayout.test .target {
+.v-layout.test .target {
        outline: 2px dashed blue;
 }
 
index cea75a3bfd2bdfe0d182514b4ae88d5d6568255e..30426e139922c81d262004f8e9cc913a003c71e0 100644 (file)
@@ -25,6 +25,7 @@ import com.google.gwt.user.client.ui.SimplePanel;
 import com.google.gwt.user.client.ui.Widget;
 import com.vaadin.client.ApplicationConnection;
 import com.vaadin.client.VCaption;
+import com.vaadin.ui.themes.BaseTheme;
 
 public class VAbsoluteLayout extends ComplexPanel {
 
@@ -44,7 +45,8 @@ public class VAbsoluteLayout extends ComplexPanel {
 
     public VAbsoluteLayout() {
         setElement(Document.get().createDivElement());
-        setStyleName(CLASSNAME);
+        setStyleName(BaseTheme.UI_LAYOUT);
+        addStyleName(CLASSNAME);
         marginElement = Document.get().createDivElement();
         canvas.getStyle().setProperty("position", "relative");
         canvas.getStyle().setProperty("overflow", "hidden");
index e7c78fadb2cf13b38ca0b854a2ad6378fc543b45..2aeec53e278a4b63184d3b06a8b66fa12cf50a2c 100644 (file)
@@ -1,4 +1,4 @@
-/* 
+/*
  * Copyright 2011 Vaadin Ltd.
  * 
  * Licensed under the Apache License, Version 2.0 (the "License"); you may not
@@ -21,6 +21,7 @@ import com.google.gwt.user.client.Element;
 import com.google.gwt.user.client.ui.FlowPanel;
 import com.google.gwt.user.client.ui.SimplePanel;
 import com.google.gwt.user.client.ui.Widget;
+import com.vaadin.ui.themes.BaseTheme;
 
 public class VCssLayout extends SimplePanel {
     public static final String TAGNAME = "csslayout";
@@ -33,7 +34,8 @@ public class VCssLayout extends SimplePanel {
     public VCssLayout() {
         super();
         getElement().appendChild(margin);
-        setStyleName(CLASSNAME);
+        setStyleName(BaseTheme.UI_LAYOUT);
+        addStyleName(CLASSNAME);
         margin.setClassName(CLASSNAME + "-margin");
         setWidget(panel);
     }
index aecbb73cb887d5aa77cdd5da4424d1957675c730..963ad5becf19622ddc65d9f3e12447ca97766fe5 100644 (file)
@@ -1,4 +1,4 @@
-/* 
+/*
  * Copyright 2011 Vaadin Ltd.
  * 
  * Licensed under the Apache License, Version 2.0 (the "License"); you may not
@@ -32,6 +32,7 @@ import com.vaadin.client.ComponentConnector;
 import com.vaadin.client.Util;
 import com.vaadin.client.VCaption;
 import com.vaadin.client.VCaptionWrapper;
+import com.vaadin.ui.themes.BaseTheme;
 
 /**
  * Custom Layout implements complex layout defined with HTML template.
@@ -82,7 +83,8 @@ public class VCustomLayout extends ComplexPanel {
             DOM.setStyleAttribute(getElement(), "position", "relative");
         }
 
-        setStyleName(CLASSNAME);
+        setStyleName(BaseTheme.UI_LAYOUT);
+        addStyleName(CLASSNAME);
     }
 
     /**
@@ -207,7 +209,7 @@ public class VCustomLayout extends ComplexPanel {
     static native void eval(String script)
     /*-{
       try {
-        if (script != null) 
+        if (script != null)
       eval("{ var document = $doc; var window = $wnd; "+ script + "}");
       } catch (e) {
       }
index f2f6e0bc726c4de4f4e88a52e46656793afa5b60..49df49374d46d9a84e5e275fb1a95613fda59b67 100644 (file)
@@ -40,6 +40,7 @@ import com.vaadin.shared.ComponentConstants;
 import com.vaadin.shared.ComponentState;
 import com.vaadin.shared.ui.ComponentStateUtil;
 import com.vaadin.shared.ui.MarginInfo;
+import com.vaadin.ui.themes.BaseTheme;
 
 /**
  * Two col Layout that places caption on left col and field on right col
@@ -52,7 +53,8 @@ public class VFormLayout extends SimplePanel {
 
     public VFormLayout() {
         super();
-        setStyleName(CLASSNAME);
+        setStyleName(BaseTheme.UI_LAYOUT);
+        addStyleName(CLASSNAME);
         table = new VFormLayoutTable();
         setWidget(table);
     }
index d3b2f0467e6192004442d8d119a45cb6dd898159..894b21c9256541ee2a19c7f3efc79e87f35933d4 100644 (file)
@@ -39,6 +39,7 @@ import com.vaadin.client.ui.layout.ComponentConnectorLayoutSlot;
 import com.vaadin.client.ui.layout.VLayoutSlot;
 import com.vaadin.shared.ui.AlignmentInfo;
 import com.vaadin.shared.ui.MarginInfo;
+import com.vaadin.ui.themes.BaseTheme;
 
 public class VGridLayout extends ComplexPanel {
 
@@ -70,7 +71,8 @@ public class VGridLayout extends ComplexPanel {
         spacingStyle.setPosition(Position.ABSOLUTE);
         getElement().appendChild(spacingMeasureElement);
 
-        setStyleName(CLASSNAME);
+        setStyleName(BaseTheme.UI_LAYOUT);
+        addStyleName(CLASSNAME);
     }
 
     private GridLayoutConnector getConnector() {
index 543eeafe88d43376e4e62beac27a67cad5d785be..f80db5113f00d05b2cb818a2e513f3ea496ebed2 100644 (file)
@@ -20,10 +20,13 @@ package com.vaadin.client.ui.orderedlayout;
  */
 public class VHorizontalLayout extends VOrderedLayout {
 
+    private static final String CLASSNAME = "v-horizontallayout";
+
     /**
      * Default constructor
      */
     public VHorizontalLayout() {
         setVertical(false);
+        addStyleName(CLASSNAME);
     }
 }
index 7dc816f2877928133b0360c7a31c8d8552a0cf87..b97ffdc394b5ce68fd8cd029cdfaa4d8187aa615 100644 (file)
@@ -42,8 +42,6 @@ import com.vaadin.ui.themes.BaseTheme;
  */
 public class VOrderedLayout extends FlowPanel {
 
-    public static final String CLASSNAME = "v-boxlayout";
-
     private static final String ALIGN_CLASS_PREFIX = "v-align-";
 
     protected boolean spacing = false;
@@ -62,7 +60,7 @@ public class VOrderedLayout extends FlowPanel {
      * Constructor
      */
     public VOrderedLayout() {
-        setStyleName(CLASSNAME);
+        setStyleName(BaseTheme.UI_LAYOUT);
         setVertical(true);
     }
 
index 3e597afec1fa9a63ff59dc391fc4b6bb787a922e..17de447b9a1a80e3d71c4080a631f18b3a850983 100644 (file)
@@ -20,10 +20,13 @@ package com.vaadin.client.ui.orderedlayout;
  */
 public class VVerticalLayout extends VOrderedLayout {
 
+    private static final String CLASSNAME = "v-verticallayout";
+
     /**
      * Default constructor
      */
     public VVerticalLayout() {
         setVertical(true);
+        addStyleName(CLASSNAME);
     }
 }
index 61e274825769af2b87bc07c13476bd3c05d810cb..ef19b83c206bdc4ee091b08e83db6826957cb9fc 100644 (file)
@@ -47,6 +47,7 @@ import com.vaadin.client.ui.TouchScrollDelegate;
 import com.vaadin.client.ui.TouchScrollDelegate.TouchScrollHandler;
 import com.vaadin.client.ui.VOverlay;
 import com.vaadin.client.ui.splitpanel.VAbstractSplitPanel.SplitterMoveHandler.SplitterMoveEvent;
+import com.vaadin.ui.themes.BaseTheme;
 
 public class VAbstractSplitPanel extends ComplexPanel {
 
@@ -117,13 +118,14 @@ public class VAbstractSplitPanel extends ComplexPanel {
 
     public VAbstractSplitPanel(int orientation) {
         setElement(DOM.createDiv());
+        setStyleName(BaseTheme.UI_LAYOUT);
         switch (orientation) {
         case ORIENTATION_HORIZONTAL:
-            setStyleName(CLASSNAME + "-horizontal");
+            addStyleName(CLASSNAME + "-horizontal");
             break;
         case ORIENTATION_VERTICAL:
         default:
-            setStyleName(CLASSNAME + "-vertical");
+            addStyleName(CLASSNAME + "-vertical");
             break;
         }
         // size below will be overridden in update from uidl, initial size
index ea5ba54f532860123c6579a94700e75f32f85539..9148dd063cf47202a01bdf11eadcbfd95eb26047 100644 (file)
@@ -61,4 +61,9 @@ public class BaseTheme {
      */
     public static final String UI_WIDGET = "v-widget";
 
+    /**
+     * Added to all layouts to denote they are layouts
+     */
+    public static final String UI_LAYOUT = "v-layout";
+
 }
\ No newline at end of file