Bug 69781 - [WK2] Add a C API to inspect injected bundle path associated with a WKContextRef
Summary: [WK2] Add a C API to inspect injected bundle path associated with a WKContextRef
Status: NEW
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebKit2 (show other bugs)
Version: 528+ (Nightly build)
Hardware: All All
: P2 Normal
Assignee: Nobody
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-10-10 13:49 PDT by Siddharth Mathur
Modified: 2012-01-22 14:22 PST (History)
5 users (show)

See Also:


Attachments
Patch contains new API WKContextGetInjectedBundlePath to inspect injected bundle path associated with a WKContextRef (1.88 KB, patch)
2011-10-21 04:48 PDT, Vamshikrishna Yellenki
kling: review-
Details | Formatted Diff | Diff
Updated the new patch (1.88 KB, patch)
2011-10-21 05:23 PDT, Vamshikrishna Yellenki
sam: review-
fbqw68: commit-queue?
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Siddharth Mathur 2011-10-10 13:49:26 PDT
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.
Comment 1 Sam Weinig 2011-10-10 18:10:38 PDT
This seems like an acceptable API addition to me.
Comment 2 Vamshikrishna Yellenki 2011-10-21 04:48:18 PDT
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 3 Andreas Kling 2011-10-21 05:10:42 PDT
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.
Comment 4 Vamshikrishna Yellenki 2011-10-21 05:23:22 PDT
Created attachment 111950 [details]
Updated the new patch
Comment 5 Adam Roben (:aroben) 2011-10-21 06:41:55 PDT
Comment on attachment 111950 [details]
Updated the new patch

This could use a test. You should be able to add one to TestWebKitAPI.
Comment 6 Sam Weinig 2012-01-22 14:22:06 PST
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.