summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--WebContent/VAADIN/themes/base/absolutelayout/absolutelayout.css12
-rw-r--r--src/com/vaadin/terminal/gwt/client/ui/VAbsoluteLayout.java19
2 files changed, 14 insertions, 17 deletions
diff --git a/WebContent/VAADIN/themes/base/absolutelayout/absolutelayout.css b/WebContent/VAADIN/themes/base/absolutelayout/absolutelayout.css
index b2c2ed2858..fba94a8edc 100644
--- a/WebContent/VAADIN/themes/base/absolutelayout/absolutelayout.css
+++ b/WebContent/VAADIN/themes/base/absolutelayout/absolutelayout.css
@@ -1,4 +1,14 @@
.v-absolutelayout-wrapper {
position: absolute;
overflow: hidden;
-} \ No newline at end of file
+}
+.v-absolutelayout-margin, .v-absolutelayout-canvas {
+ box-sizing: border-box;
+ -moz-box-sizing: border-box;
+}
+.v-absolutelayout.v-has-height > div, .v-absolutelayout.v-has-height > div > div {
+ height: 100%;
+}
+.v-absolutelayout.v-has-width > div, .v-absolutelayout.v-has-width > div > div {
+ width: 100%;
+}
diff --git a/src/com/vaadin/terminal/gwt/client/ui/VAbsoluteLayout.java b/src/com/vaadin/terminal/gwt/client/ui/VAbsoluteLayout.java
index 48c6109f44..88f525cb4e 100644
--- a/src/com/vaadin/terminal/gwt/client/ui/VAbsoluteLayout.java
+++ b/src/com/vaadin/terminal/gwt/client/ui/VAbsoluteLayout.java
@@ -47,6 +47,9 @@ public class VAbsoluteLayout extends ComplexPanel {
canvas.getStyle().setProperty("overflow", "hidden");
marginElement.appendChild(canvas);
getElement().appendChild(marginElement);
+
+ canvas.setClassName(CLASSNAME + "-canvas");
+ canvas.setClassName(CLASSNAME + "-margin");
}
AbsoluteWrapper getWrapper(ApplicationConnection client, UIDL componentUIDL) {
@@ -66,22 +69,6 @@ public class VAbsoluteLayout extends ComplexPanel {
super.add(child, canvas);
}
- @Override
- public void setWidth(String width) {
- super.setWidth(width);
- // TODO do this so that canvas gets the sized properly (the area
- // inside marginals)
- canvas.getStyle().setProperty("width", width);
- }
-
- @Override
- public void setHeight(String height) {
- super.setHeight(height);
- // TODO do this so that canvas gets the sized properly (the area
- // inside marginals)
- canvas.getStyle().setProperty("height", height);
- }
-
public class AbsoluteWrapper extends SimplePanel {
private String css;
String left;