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

Unified Diff: chrome/test/data/webui/splitter_test.html

Issue 1711233003: Bookmarks: fix splitter right mousedown issue (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 10 months 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
« no previous file with comments | « no previous file | chrome/test/data/webui/webui_resource_browsertest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/test/data/webui/splitter_test.html
diff --git a/chrome/test/data/webui/splitter_test.html b/chrome/test/data/webui/splitter_test.html
new file mode 100644
index 0000000000000000000000000000000000000000..9d4a567b82a56797d4a32ba21a8e7b578e73ece8
--- /dev/null
+++ b/chrome/test/data/webui/splitter_test.html
@@ -0,0 +1,22 @@
+<!doctype html>
+<html>
+<body>
+<div></div>
+<div id="splitter"></div>
+<div></div>
+<script>
+function testSplitter_IgnoresRightMouse() {
+ var splitter = document.getElementById('splitter');
+ cr.ui.decorate(splitter, cr.ui.Splitter);
+
+ var downRight = new MouseEvent('mousedown', {button: 1, cancelable: true});
+ assertTrue(splitter.dispatchEvent(downRight));
+ assertFalse(downRight.defaultPrevented);
+
+ var downLeft = new MouseEvent('mousedown', {button: 0, cancelable: true});
+ assertFalse(splitter.dispatchEvent(downLeft));
+ assertTrue(downLeft.defaultPrevented);
+}
+</script>
+</body>
+</html>
« no previous file with comments | « no previous file | chrome/test/data/webui/webui_resource_browsertest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698