It would be nice to have a API in WKContext.h which allows the path (WKStringRef) of the associated injected bundle to be inspected. I.e users of WKContextCreateWithInjectedBundlePath(WKStringRef path) should be able inspect the path at any time given only a WKContextRef.
This seems like an acceptable API addition to me.
Created attachment 111943 [details] Patch contains new API WKContextGetInjectedBundlePath to inspect injected bundle path associated with a WKContextRef Patch contains new API WKContextGetInjectedBundlePath to inspect injected bundle path associated with a WKContextRef
Comment on attachment 111943 [details] Patch contains new API WKContextGetInjectedBundlePath to inspect injected bundle path associated with a WKContextRef View in context: https://bugs.webkit.org/attachment.cgi?id=111943&action=review Please set r? if you want a patch to be reviewed. :) > Source/WebKit2/UIProcess/API/C/WKContext.cpp:67 > +WKStringRef WKContextGetInjectedBundlePath(WKContextRef contextRef) > +{ > + return toCopiedAPI(toImpl(contextRef)->injectedBundlePath()); > +} This should be called WKContextCopyInjectedBundlePath since it returns a copy.
Created attachment 111950 [details] Updated the new patch
Comment on attachment 111950 [details] Updated the new patch This could use a test. You should be able to add one to TestWebKitAPI.
Comment on attachment 111950 [details] Updated the new patch View in context: https://bugs.webkit.org/attachment.cgi?id=111950&action=review r- for lack of test. > Source/WebKit2/UIProcess/API/C/WKContext.h:112 > +WK_EXPORT WKStringRef WKContextCopyInjectedBundlePath(WKContextRef context); This should move our of the group of create/get WKContextRef functions.