[Webkit-unassigned] [Bug 77835] [GObject bindings] EventListeners as first-class GObjects: WebKitDOMEventListener

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Tue Oct 22 01:20:26 PDT 2013


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





--- Comment #63 from Carlos Garcia Campos <cgarcia at igalia.com>  2013-10-22 01:19:10 PST ---
There's another thing I don't understand about the EventTarget interface exposed in the GObject bindings. The interface is defined as:

void addEventListener(DOMString type, 
                          EventListener listener, 
                          optional boolean useCapture);
void removeEventListener(DOMString type, 
                             EventListener listener, 
                             optional boolean useCapture);
[RaisesException] boolean dispatchEvent(Event event);

And we do exactly the opposite wrt to the return values, we return a boolean from add/remove_event_listener and void in dispatch_event. But then, we expose dispatch_event as public API in objects implementing the EventTarget interface returning a boolean. I thought about deprecating all the public dispatch_event in favor of using the interface, but those public methods are the only way to get the return value of dispatchEvent.

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.


More information about the webkit-unassigned mailing list