summaryrefslogtreecommitdiffstats
path: root/Source/WebCore/dom/KeyboardEvent.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'Source/WebCore/dom/KeyboardEvent.cpp')
-rw-r--r--Source/WebCore/dom/KeyboardEvent.cpp7
1 files changed, 7 insertions, 0 deletions
diff --git a/Source/WebCore/dom/KeyboardEvent.cpp b/Source/WebCore/dom/KeyboardEvent.cpp
index 7b0f3af..109135d 100644
--- a/Source/WebCore/dom/KeyboardEvent.cpp
+++ b/Source/WebCore/dom/KeyboardEvent.cpp
@@ -25,6 +25,7 @@
#include "Document.h"
#include "DOMWindow.h"
+#include "EventDispatcher.h"
#include "EventNames.h"
#include "EventHandler.h"
#include "Frame.h"
@@ -160,4 +161,10 @@ KeyboardEvent* findKeyboardEvent(Event* event)
return 0;
}
+bool KeyboardEvent::dispatch(EventDispatcher* dispatcher)
+{
+ // Make sure not to return true if we already took default action while handling the event.
+ return dispatcher->dispatchEvent(this) && !defaultHandled();
+}
+
} // namespace WebCore