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

Unified Diff: LayoutTests/fast/events/button-mouse-active.html

Issue 291563009: Don't repaint button when its click() method is called (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: NeedsRebaseline on mac Created 6 years, 7 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 | « LayoutTests/TestExpectations ('k') | LayoutTests/fast/events/button-mouse-active-expected.txt » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: LayoutTests/fast/events/button-mouse-active.html
diff --git a/LayoutTests/fast/events/button-mouse-active.html b/LayoutTests/fast/events/button-mouse-active.html
new file mode 100644
index 0000000000000000000000000000000000000000..16988d6528d100dcd6f094c974e07ae4962f0a5d
--- /dev/null
+++ b/LayoutTests/fast/events/button-mouse-active.html
@@ -0,0 +1,26 @@
+<!DOCTYPE html>
+<script src="../../resources/js-test.js"></script>
+<script>
+if (window.testRunner)
+ testRunner.dumpAsText();
+
+window.onload = function() {
+ if (window.eventSender) {
+ var button = document.getElementById('button');
+ eventSender.mouseMoveTo(button.offsetLeft + button.offsetWidth / 2,
+ button.offsetTop + button.offsetTop / 2);
+
+ eventSender.mouseDown();
+ shouldBeEqualToString('getComputedStyle(button).backgroundColor', 'rgb(0, 255, 0)');
+
+ eventSender.mouseUp();
+ shouldBeEqualToString('getComputedStyle(button).backgroundColor', 'rgb(0, 0, 255)');
+ }
+};
+</script>
+<style>
+button { background-color: rgb(0, 0, 255); }
+button:active { background-color: rgb(0, 255, 0); }
+</style>
+<button id="button">button</button>
+<div id="console"></div>
« no previous file with comments | « LayoutTests/TestExpectations ('k') | LayoutTests/fast/events/button-mouse-active-expected.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698