[webkit-dev] Does any port implements Navigator.registerProtocolHandler and Navigator.registerContentHandler?
Darin Adler
darin at apple.com
Thu Jul 22 19:07:04 PDT 2010
On Jul 22, 2010, at 2:12 PM, Gustavo Sverzut Barbieri wrote:
> Sorry to disturb this already dead thread, but we're (webkit-efl) thinking of letting applications/browsers register new protocol handlers to provide contents themselves. A co-worker, Flávio Ceolin, will send more details in another thread, but do you have any idea on the path to have them generically in WebCore?
WebKit on Mac OS X already supports this and most other ports as well. Adding it to a platform does not require any changes to WebCore.
The frame policy functions in FrameLoaderClient are the hook for this sort of thing, specifically dispatchDecidePolicyForNavigationAction. WebKit looks at the URL and decides it’s something an application can handle based on the OS-specific system for handling such things. Then if it does want to handle it, it calls the frame policy function with the action "ignore", which prevents WebCore from doing anything with the link, and then passes the URL on to the other application.
-- Darin
More information about the webkit-dev
mailing list