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 9fc74636c39363875c9aa7c4b97e7dd8a607457a..c97e26fa9dd7a916c354683ad27b23530250e0d1 100644 |
--- a/LayoutTests/fast/events/frame-tab-focus.html |
+++ b/LayoutTests/fast/events/frame-tab-focus.html |
@@ -86,10 +86,14 @@ function setupWindow(win) |
function dispatchTabPress(element, shiftKey, altKey) |
{ |
- 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); |
+ if (window.eventSender) { |
+ modifiers = []; |
+ if (shiftKey) |
+ modifiers.push("shiftKey"); |
+ if (altKey) |
+ modifiers.push("altKey"); |
+ eventSender.keyDown('\u0009', modifiers); |
+ } |
} |
function test() |