aboutsummaryrefslogtreecommitdiffstats
path: root/client
diff options
context:
space:
mode:
authorMarkus Koivisto <markus@vaadin.com>2014-07-30 17:28:41 +0300
committerVaadin Code Review <review@vaadin.com>2014-07-31 07:28:22 +0000
commit92da25c0b494e059985486bfaaabf434ac59afa1 (patch)
tree2e064be2bd417ac662271945d937dc107aa82331 /client
parent161d5289e23fdf1d9cb8e97d2e55f948b43fe0aa (diff)
downloadvaadin-framework-92da25c0b494e059985486bfaaabf434ac59afa1.tar.gz
vaadin-framework-92da25c0b494e059985486bfaaabf434ac59afa1.zip
Fix typo that caused spanned cells to be removed in Gridlayout (#14335)
Gridlayout removes columns and rows with no content. Gridlayout is supposed to check for spanned cells and not remove otherwise empty rows or columns if they are covered by a span. Change-Id: I1c25a8e6426e6ce0e24f9110a6b994598c395e7a
Diffstat (limited to 'client')
-rw-r--r--client/src/com/vaadin/client/ui/VGridLayout.java20
1 files changed, 10 insertions, 10 deletions
diff --git a/client/src/com/vaadin/client/ui/VGridLayout.java b/client/src/com/vaadin/client/ui/VGridLayout.java
index 10e5c00a38..17131ce63b 100644
--- a/client/src/com/vaadin/client/ui/VGridLayout.java
+++ b/client/src/com/vaadin/client/ui/VGridLayout.java
@@ -95,7 +95,7 @@ public class VGridLayout extends ComplexPanel {
/**
* Returns the column widths measured in pixels
- *
+ *
* @return
*/
protected int[] getColumnWidths() {
@@ -104,7 +104,7 @@ public class VGridLayout extends ComplexPanel {
/**
* Returns the row heights measured in pixels
- *
+ *
* @return
*/
protected int[] getRowHeights() {
@@ -113,7 +113,7 @@ public class VGridLayout extends ComplexPanel {
/**
* Returns the spacing between the cells horizontally in pixels
- *
+ *
* @return
*/
protected int getHorizontalSpacing() {
@@ -122,7 +122,7 @@ public class VGridLayout extends ComplexPanel {
/**
* Returns the spacing between the cells vertically in pixels
- *
+ *
* @return
*/
protected int getVerticalSpacing() {
@@ -271,7 +271,7 @@ public class VGridLayout extends ComplexPanel {
}
for (SpanList l : rowSpans) {
for (Cell cell : l.cells) {
- if (cell.row >= i && i < cell.row + cell.rowspan) {
+ if (cell.row <= i && i < cell.row + cell.rowspan) {
return true;
}
}
@@ -287,7 +287,7 @@ public class VGridLayout extends ComplexPanel {
}
for (SpanList l : colSpans) {
for (Cell cell : l.cells) {
- if (cell.col >= i && i < cell.col + cell.colspan) {
+ if (cell.col <= i && i < cell.col + cell.colspan) {
return true;
}
}
@@ -751,7 +751,7 @@ public class VGridLayout extends ComplexPanel {
* Creates a new Cell with the given coordinates.
* <p>
* For internal use only. May be removed or replaced in the future.
- *
+ *
* @param row
* @param col
* @return
@@ -767,7 +767,7 @@ public class VGridLayout extends ComplexPanel {
* child component is also returned if "element" is part of its caption.
* <p>
* For internal use only. May be removed or replaced in the future.
- *
+ *
* @param element
* An element that is a nested sub element of the root element in
* this layout
@@ -788,13 +788,13 @@ public class VGridLayout extends ComplexPanel {
* child component is also returned if "element" is part of its caption.
* <p>
* For internal use only. May be removed or replaced in the future.
- *
+ *
* @param element
* An element that is a nested sub element of the root element in
* this layout
* @return The Paintable which the element is a part of. Null if the element
* belongs to the layout and not to a child.
- *
+ *
* @since 7.2
*/
public ComponentConnector getComponent(Element element) {