[webkit-dev] C++ callback at same-ish point as DOMContentLoaded javascript event?

Aaron Boodman aa at google.com
Sun Nov 16 14:53:35 PST 2008


Hello all,

I'd like to run some C++ around the same point as the DOMContentLoaded
event is fired. Importantly, I need this to happen *before* the
window's onload event fires.

FrameLoaderClient::dispatchDidFinishDocumentLoad is usually fired at
the right point, but it can sometimes happen after window.onload.
Would a patch to add something like
dispatchDidHandleDOMContentLoadedEvents to FrameLoaderClient be
accepted? Or is there some better way to do what I want?

(FWIW, this is related to Chromium's fledgling Greasemonkey support.
For maximal compatibility with the Firefox version of Greasemonkey,
it's important that scripts be injected before window.onload).

Thanks,

- a


More information about the webkit-dev mailing list