Commit 313e2a05 authored by abarth@webkit.org's avatar abarth@webkit.org

Add WebNode::hasEventListeners for Android

https://bugs.webkit.org/show_bug.cgi?id=72817

Reviewed by Darin Fisher.

Expose this EventTarget interface in the Chromium WebKit API for use by
Android.

* public/WebNode.h:
* src/WebNode.cpp:
(WebKit::WebNode::hasEventListeners):


git-svn-id: http://svn.webkit.org/repository/webkit/trunk@100871 268f45cc-cd09-0410-ab3c-d52691b4dbfc
parent e808045f
2011-11-20 Adam Barth <abarth@webkit.org>
Add WebNode::hasEventListeners for Android
https://bugs.webkit.org/show_bug.cgi?id=72817
Reviewed by Darin Fisher.
Expose this EventTarget interface in the Chromium WebKit API for use by
Android.
* public/WebNode.h:
* src/WebNode.cpp:
(WebKit::WebNode::hasEventListeners):
2011-11-20 Adam Barth <abarth@webkit.org>
[Chromium] Add GestureFlingStart and GestureFlingCancel to WebGestureEvent for Android
......
......@@ -65,7 +65,7 @@ public:
// Required for using WebNodes in std maps. Note the order used is
// arbitrary and should not be expected to have any specific meaning.
WEBKIT_EXPORT bool lessThan(const WebNode&) const;
bool isNull() const { return m_private.isNull(); }
enum NodeType {
......@@ -84,6 +84,7 @@ public:
XPathNamespaceNode,
ShadowRootNode
};
WEBKIT_EXPORT NodeType nodeType() const;
WEBKIT_EXPORT WebNode parentNode() const;
WEBKIT_EXPORT WebString nodeName() const;
......@@ -102,6 +103,7 @@ public:
WEBKIT_EXPORT bool isFocusable() const;
WEBKIT_EXPORT bool isContentEditable() const;
WEBKIT_EXPORT bool isElementNode() const;
WEBKIT_EXPORT bool hasEventListeners(const WebString& eventType) const;
WEBKIT_EXPORT void addEventListener(const WebString& eventType, WebDOMEventListener* listener, bool useCapture);
WEBKIT_EXPORT void removeEventListener(const WebString& eventType, WebDOMEventListener* listener, bool useCapture);
WEBKIT_EXPORT bool dispatchEvent(const WebDOMEvent&);
......
......@@ -166,6 +166,11 @@ bool WebNode::isElementNode() const
return m_private->isElementNode();
}
bool WebNode::hasEventListeners(const WebString& eventType) const
{
return m_private->hasEventListeners(eventType);
}
void WebNode::addEventListener(const WebString& eventType, WebDOMEventListener* listener, bool useCapture)
{
EventListenerWrapper* listenerWrapper =
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment