[webkit-dev] dispatchEvent is a noop on documents returned by parseFromString
Loic Dachary
loic at dachary.org
Tue Oct 4 05:26:25 PDT 2011
Hi,
In the context of https://bugs.webkit.org/show_bug.cgi?id=26147 ( No support of DOM events on a frameless document ) I am researching how to implement a fix. I'm thinking of two possible solutions, none of which is trivial. Probably because I'm new to the webkit codebase.
a) modify the function
void JSEventListener::handleEvent(ScriptExecutionContext* scriptExecutionContext, Event* event)
found in http://trac.webkit.org/browser/trunk/Source/WebCore/bindings/js/JSEventListener.cpp
so that it does not return without doing anything when there is no frame. However, given the
extensive checks related to frames found in the function, I suspect that would cause more problems
than it solves.
b) modify the function
EncodedJSValue JSC_HOST_CALL jsDOMParserPrototypeFunctionParseFromString(ExecState* exec)
(or whatever generates this function) to assign the frame() of the global document to it.
However, I suspect that this will have a number of undesirable side effects.
I'm not sure if there are other ways to look for a solution. I would be very grateful if someone familiar with the codebase could provide me with a hint or point me in the right direction.
Thanks in advance
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-dev/attachments/20111004/b1702732/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: loic.vcf
Type: text/x-vcard
Size: 327 bytes
Desc: not available
URL: <http://lists.webkit.org/pipermail/webkit-dev/attachments/20111004/b1702732/attachment.vcf>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 262 bytes
Desc: OpenPGP digital signature
URL: <http://lists.webkit.org/pipermail/webkit-dev/attachments/20111004/b1702732/attachment.bin>
More information about the webkit-dev
mailing list