Browse Source

fixes #3039. Added Safari scrollbar bug workaround to safari scrollbar bug workaround

svn changeset:8201/svn branch:6.0
tags/6.7.0.beta1
Matti Tahvonen 15 years ago
parent
commit
93fc4ab9f3
1 changed files with 8 additions and 1 deletions
  1. 8
    1
      src/com/vaadin/terminal/gwt/client/Util.java

+ 8
- 1
src/com/vaadin/terminal/gwt/client/Util.java View File

@@ -525,7 +525,7 @@ public class Util {
/**
* Run workaround for webkits overflow auto issue.
*
* See: our buh #2138 and https://bugs.webkit.org/show_bug.cgi?id=21462
* See: our bug #2138 and https://bugs.webkit.org/show_bug.cgi?id=21462
*
* @param elem
* with overflow auto
@@ -539,6 +539,13 @@ public class Util {
public void execute() {
// Dough, safari scoll auto means actually just a moped
elem.getStyle().setProperty("overflow", "auto");
if (elem.getScrollTop() > 0) {
// fix another bug where scrollbar remains in wrong
// position
int scrolltop = elem.getScrollTop();
elem.setScrollTop(scrolltop + 1);
elem.setScrollTop(scrolltop);
}
}
});
}

Loading…
Cancel
Save