diff options
Diffstat (limited to 'client')
-rw-r--r-- | client/src/main/java/com/vaadin/client/ui/panel/PanelConnector.java | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/client/src/main/java/com/vaadin/client/ui/panel/PanelConnector.java b/client/src/main/java/com/vaadin/client/ui/panel/PanelConnector.java index 2e5237598f..5e22b9ef32 100644 --- a/client/src/main/java/com/vaadin/client/ui/panel/PanelConnector.java +++ b/client/src/main/java/com/vaadin/client/ui/panel/PanelConnector.java @@ -226,7 +226,14 @@ public class PanelConnector extends AbstractSingleComponentContainerConnector public void postLayout() { VPanel panel = getWidget(); if (uidlScrollTop != null) { + // IE / Safari fix for when scroll top is set to greater than panel + // height + int maxScroll = panel.getWidget().getOffsetHeight(); + if (uidlScrollTop > maxScroll) { + uidlScrollTop = maxScroll; + } panel.contentNode.setScrollTop(uidlScrollTop.intValue()); + // Read actual value back to ensure update logic is correct // TODO Does this trigger reflows? panel.scrollTop = panel.contentNode.getScrollTop(); |