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

Unified Diff: LayoutTests/fast/events/frame-tab-focus.html

Issue 1251043004: Revert of Only execute default actions on trusted events. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master_event_trusted_main3
Patch Set: Created 5 years, 5 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
Index: LayoutTests/fast/events/frame-tab-focus.html
diff --git a/LayoutTests/fast/events/frame-tab-focus.html b/LayoutTests/fast/events/frame-tab-focus.html
index c97e26fa9dd7a916c354683ad27b23530250e0d1..9fc74636c39363875c9aa7c4b97e7dd8a607457a 100644
--- a/LayoutTests/fast/events/frame-tab-focus.html
+++ b/LayoutTests/fast/events/frame-tab-focus.html
@@ -86,14 +86,10 @@
function dispatchTabPress(element, shiftKey, altKey)
{
- if (window.eventSender) {
- modifiers = [];
- if (shiftKey)
- modifiers.push("shiftKey");
- if (altKey)
- modifiers.push("altKey");
- eventSender.keyDown('\u0009', modifiers);
- }
+ var event = document.createEvent('KeyboardEvents');
+ var tabKeyIdentifier = 'U+0009';
+ event.initKeyboardEvent('keydown', true, true, document.defaultView, tabKeyIdentifier, 0, false, altKey, shiftKey, false, false);
+ element.dispatchEvent(event);
}
function test()

Powered by Google App Engine
This is Rietveld 408576698