Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(415)

Unified Diff: LayoutTests/fast/events/wheelevent-ctrl.html

Issue 768443002: Honor the wheel event canScroll bit instead of trying to infer it from the ctrl modifier (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 6 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: LayoutTests/fast/events/wheelevent-ctrl.html
diff --git a/LayoutTests/fast/events/wheelevent-ctrl.html b/LayoutTests/fast/events/wheelevent-ctrl.html
index 6b2b45537a9a18b895899062a2620e9274450939..7d19155207592695e012b1104f037f02d8971709 100644
--- a/LayoutTests/fast/events/wheelevent-ctrl.html
+++ b/LayoutTests/fast/events/wheelevent-ctrl.html
@@ -20,16 +20,16 @@ function runTest() {
debug('Test mousewheel events over scrollable div');
tdresser 2014/11/27 15:06:09 Can we write a test which has different expectatio
Rick Byers 2014/11/27 18:05:54 Layout tests really test only blink (at least in t
lanwei 2014/12/02 15:48:10 Done.
- debug('With ctrl modifier set');
+ debug('With ctrl modifier set and suppressScroll set to be true');
wheelEventCount = 0;
eventSender.mouseMoveTo(testDiv.offsetLeft + 5, testDiv.offsetTop + 5);
- eventSender.mouseScrollBy(0, scrollAmount, false, true, "ctrlKey");
+ eventSender.mouseScrollBy(0, scrollAmount, false, true, "ctrlKey", true);
shouldBe("wheelEventCount", "1");
shouldEvaluateTo("deltaY", expectedDeltaY);
shouldBeTrue("ctrlKey");
shouldBe("testDiv.scrollTop", "0");
- debug('Without ctrl');
+ debug('Without ctrl and suppressScroll set to be default false');
wheelEventCount = 0;
eventSender.mouseMoveTo(testDiv.offsetLeft + 5, testDiv.offsetTop + 5);
eventSender.mouseScrollBy(0, scrollAmount, false, true);
@@ -42,16 +42,16 @@ function runTest() {
debug('Test mousewheel events over the document');
testDiv = document.getElementById('target2');
- debug('With ctrl modifier set');
+ debug('With ctrl modifier set and suppressScroll set to be true');
wheelEventCount = 0;
eventSender.mouseMoveTo(testDiv.offsetLeft + 5, testDiv.offsetTop + 5);
- eventSender.mouseScrollBy(0, scrollAmount, false, true, "ctrlKey");
+ eventSender.mouseScrollBy(0, scrollAmount, false, true, "ctrlKey", true);
shouldBe("wheelEventCount", "1");
shouldEvaluateTo("deltaY", expectedDeltaY);
shouldBeTrue("ctrlKey");
- shouldBe("document.body.scrollTop", "0");
+ shouldBe("window.scrollY", "0");
- debug('Now without ctrl');
+ debug('Now without ctrl and suppressScroll set to be default false');
wheelEventCount = 0;
eventSender.mouseMoveTo(testDiv.offsetLeft + 5, testDiv.offsetTop + 5);
eventSender.mouseScrollBy(0, scrollAmount, false, true);
« no previous file with comments | « no previous file | LayoutTests/fast/events/wheelevent-ctrl-expected.txt » ('j') | Source/core/page/EventHandler.cpp » ('J')

Powered by Google App Engine
This is Rietveld 408576698