]> source.dussan.org Git - vaadin-framework.git/commitdiff
Add getter to SplitterState.positionReversed (#15285)
authorAnna Koskinen <anna@vaadin.com>
Tue, 25 Nov 2014 15:23:45 +0000 (17:23 +0200)
committerAnna Koskinen <anna@vaadin.com>
Tue, 25 Nov 2014 16:07:02 +0000 (18:07 +0200)
Change-Id: I1e3783d21cb5f2832838dfe36c91c7f6a4ddb313

server/src/com/vaadin/ui/AbstractSplitPanel.java

index 09f881cf461b687ef5ce098912020c12e88ca6e1..e9b37f8cff63a20aac35305e93726eb017eb28b3 100644 (file)
@@ -342,11 +342,25 @@ public abstract class AbstractSplitPanel extends AbstractComponentContainer {
      * Returns the unit of position of the splitter
      * 
      * @return unit of position of the splitter
+     * @see #setSplitPosition(float, Unit)
      */
     public Unit getSplitPositionUnit() {
         return posUnit;
     }
 
+    /**
+     * Is the split position reversed. By default the split position is measured
+     * by the first region, but if split position is reversed the measuring is
+     * done by the second region instead.
+     * 
+     * @since
+     * @return {@code true} if reversed, {@code false} otherwise.
+     * @see #setSplitPosition(float, boolean)
+     */
+    public boolean isSplitPositionReversed() {
+        return getSplitterState(false).positionReversed;
+    }
+
     /**
      * Sets the minimum split position to the given position and unit. If the
      * split position is reversed, maximum and minimum are also reversed.