зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1161634 - Enable the test_wheel_scroll on Linux as well. r=mstange
This commit is contained in:
Родитель
edf33626d4
Коммит
05c5790ec1
|
@ -17,6 +17,7 @@ function nativeVerticalWheelEventMsg() {
|
||||||
switch (getPlatform()) {
|
switch (getPlatform()) {
|
||||||
case "windows": return 0x020A; // WM_MOUSEWHEEL
|
case "windows": return 0x020A; // WM_MOUSEWHEEL
|
||||||
case "mac": return 0; // value is unused, can be anything
|
case "mac": return 0; // value is unused, can be anything
|
||||||
|
case "linux": return 4; // value is unused, pass GDK_SCROLL_SMOOTH anyway
|
||||||
}
|
}
|
||||||
throw "Native wheel events not supported on platform " + getPlatform();
|
throw "Native wheel events not supported on platform " + getPlatform();
|
||||||
}
|
}
|
||||||
|
@ -25,6 +26,7 @@ function nativeHorizontalWheelEventMsg() {
|
||||||
switch (getPlatform()) {
|
switch (getPlatform()) {
|
||||||
case "windows": return 0x020E; // WM_MOUSEHWHEEL
|
case "windows": return 0x020E; // WM_MOUSEHWHEEL
|
||||||
case "mac": return 0; // value is unused, can be anything
|
case "mac": return 0; // value is unused, can be anything
|
||||||
|
case "linux": return 4; // value is unused, pass GDK_SCROLL_SMOOTH anyway
|
||||||
}
|
}
|
||||||
throw "Native wheel events not supported on platform " + getPlatform();
|
throw "Native wheel events not supported on platform " + getPlatform();
|
||||||
}
|
}
|
||||||
|
|
|
@ -10,4 +10,4 @@ skip-if = toolkit != 'gonk' # bug 991198
|
||||||
[test_bug1151663.html]
|
[test_bug1151663.html]
|
||||||
skip-if = toolkit != 'gonk' # bug 991198
|
skip-if = toolkit != 'gonk' # bug 991198
|
||||||
[test_wheel_scroll.html]
|
[test_wheel_scroll.html]
|
||||||
skip-if = toolkit != 'windows' && toolkit != 'cocoa'
|
skip-if = (os == 'android') || (os == 'b2g') # wheel events not supported
|
||||||
|
|
|
@ -99,8 +99,15 @@ function continueTest() {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function startTest() {
|
||||||
|
// If we allow smooth scrolling the "smooth" scrolling may cause the page to
|
||||||
|
// glide past the scrollbox (which is supposed to stop the scrolling) and so
|
||||||
|
// we might end up at the bottom of the page.
|
||||||
|
SpecialPowers.pushPrefEnv({"set": [["general.smoothScroll", false]]}, continueTest);
|
||||||
|
}
|
||||||
|
|
||||||
SimpleTest.waitForExplicitFinish();
|
SimpleTest.waitForExplicitFinish();
|
||||||
SimpleTest.waitForFocus(continueTest, window);
|
SimpleTest.waitForFocus(startTest, window);
|
||||||
|
|
||||||
</script>
|
</script>
|
||||||
</pre>
|
</pre>
|
||||||
|
|
Загрузка…
Ссылка в новой задаче