Przeglądaj źródła

Enable native scrolling in all iOS versions newer than 5, not just iOS 6 (#12324)

Change-Id: I8f9ec7f34aefa5b48fd23f3f000f9455475edefa
tags/7.1.7
Johannes Dahlström 10 lat temu
rodzic
commit
cdb9a49bd5

+ 5
- 3
WebContent/VAADIN/themes/base/common/common.scss Wyświetl plik

@@ -227,11 +227,13 @@ input::-ms-clear {
font-size: 0;
line-height: normal;
}

/* Enable kinetic scrolling on iOS 6 */
.v-ios6.v-webkit & .v-scrollable {
.v-ios.v-webkit & .v-scrollable {
-webkit-overflow-scrolling: touch;
}
/* Disable native scrolling on iOS 5 due to #8792 */
.v-ios5.v-webkit & .v-scrollable {
-webkit-overflow-scrolling: none;
}

&.v-overlay-container {
width: 0;

+ 4
- 4
client/src/com/vaadin/client/BrowserInfo.java Wyświetl plik

@@ -207,8 +207,8 @@ public class BrowserInfo {
return prefix + OS_ANDROID;
} else if (browserDetails.isIOS()) {
String iosClass = prefix + OS_IOS;
if (isIOS6()) {
iosClass += " " + prefix + OS_IOS + "6";
if (getOperatingSystemMajorVersion() == 5) {
iosClass += " " + prefix + OS_IOS + "5";
}
return iosClass;
} else if (browserDetails.isWindows()) {
@@ -392,9 +392,9 @@ public class BrowserInfo {
if (isAndroid() && isWebkit() && getWebkitVersion() >= 534) {
return false;
}
// iOS 6 Safari supports native scrolling; iOS 5 suffers from #8792
// iOS 6+ Safari supports native scrolling; iOS 5 suffers from #8792
// TODO Should test other iOS browsers
if (isIOS6() && isWebkit()) {
if (isIOS() && isWebkit() && getOperatingSystemMajorVersion() >= 6) {
return false;
}
return true;

Ładowanie…
Anuluj
Zapisz