]> source.dussan.org Git - vaadin-framework.git/commitdiff
Fix for #5735 - Deprecate AlignmentUtils and methods that uses it
authorArtur Signell <artur.signell@itmill.com>
Tue, 5 Oct 2010 09:27:23 +0000 (09:27 +0000)
committerArtur Signell <artur.signell@itmill.com>
Tue, 5 Oct 2010 09:27:23 +0000 (09:27 +0000)
svn changeset:15406/svn branch:6.5

src/com/vaadin/ui/AbstractOrderedLayout.java
src/com/vaadin/ui/AlignmentUtils.java
src/com/vaadin/ui/GridLayout.java

index 517c363dc81d5df81b22a5e9d53f3ba76e8a3e0a..73ab2e81fd502db7e5b54e2e396dcbe13b386da7 100644 (file)
@@ -324,6 +324,18 @@ public abstract class AbstractOrderedLayout extends AbstractLayout implements
         return (ratio == null) ? 0 : ratio.floatValue();
     }
 
+    /**
+     * Sets the component alignment using a short hand string notation.
+     * 
+     * @deprecated Replaced by
+     *             {@link #setComponentAlignment(Component, Alignment)}
+     * 
+     * @param component
+     *            A child component in this layout
+     * @param alignment
+     *            A short hand notation described in {@link AlignmentUtils}
+     */
+    @Deprecated
     public void setComponentAlignment(Component component, String alignment) {
         AlignmentUtils.setComponentAlignment(this, component, alignment);
     }
index 470c0937846cd6a1b457b5ad9ad7959b6da3c990..72c7b9e2deb3e7e969295f09a13a53dbcc34a4dc 100644 (file)
@@ -26,13 +26,16 @@ import com.vaadin.ui.Layout.AlignmentHandler;
  * 
  * r,right for right alignment
  * 
+ * @deprecated {@code AlignmentUtils} has been replaced by {@link Alignment}.
  */
-@SuppressWarnings("serial")
+@SuppressWarnings({ "serial" })
+@Deprecated
 public class AlignmentUtils implements Serializable {
 
     private static int horizontalMask = AlignmentHandler.ALIGNMENT_LEFT
             | AlignmentHandler.ALIGNMENT_HORIZONTAL_CENTER
             | AlignmentHandler.ALIGNMENT_RIGHT;
+
     private static int verticalMask = AlignmentHandler.ALIGNMENT_TOP
             | AlignmentHandler.ALIGNMENT_VERTICAL_CENTER
             | AlignmentHandler.ALIGNMENT_BOTTOM;
index 933007841c8b6aa2d5217b13dc40bd02f23f1863..b8619e5c76d5937495be43fcc0a1a1ce6b516a01 100644 (file)
@@ -1353,6 +1353,18 @@ public class GridLayout extends AbstractLayout implements
         return null;
     }
 
+    /**
+     * Sets the component alignment using a short hand string notation.
+     * 
+     * @deprecated Replaced by
+     *             {@link #setComponentAlignment(Component, Alignment)}
+     * 
+     * @param component
+     *            A child component in this layout
+     * @param alignment
+     *            A short hand notation described in {@link AlignmentUtils}
+     */
+    @Deprecated
     public void setComponentAlignment(Component component, String alignment) {
         AlignmentUtils.setComponentAlignment(this, component, alignment);
     }