Bug 140160

Summary: [WK2] Start a prototype for declarative site specific extensions
Product: WebKit Reporter: Benjamin Poulain <benjamin>
Component: New BugsAssignee: Benjamin Poulain <benjamin>
Status: RESOLVED FIXED    
Severity: Normal CC: barraclough, cmarcelo, commit-queue, japhet, kling, sam
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
Patch
none
Patch
none
Patch kling: review+

Description Benjamin Poulain 2015-01-06 17:57:03 PST
[WK2] Start a prototype for declarative site specific extensions
Comment 1 Benjamin Poulain 2015-01-06 18:38:42 PST
Created attachment 244116 [details]
Patch
Comment 2 Benjamin Poulain 2015-01-06 19:13:36 PST
Created attachment 244123 [details]
Patch
Comment 3 Benjamin Poulain 2015-01-06 21:01:37 PST
Created attachment 244136 [details]
Patch
Comment 4 Benjamin Poulain 2015-01-07 12:47:51 PST
Comment on attachment 244136 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=244136&action=review

> Source/WebKit2/UIProcess/API/Cocoa/WKProcessPoolPrivate.h:46
> +- (void)_loadContentExtensionWithIdentifier:(NSString *)identifier serializedRules:(NSString *)serializedRules successCompletionHandler:(void (^)(NSDictionary *info))successCompletionHandler errorCompletionHandler:(void (^)(NSError *error))errorCompletionHandler;

Add
FIXME: move the API to a better place.
Comment 5 Andreas Kling 2015-01-08 17:01:30 PST
Comment on attachment 244136 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=244136&action=review

r=me. This seems like a good-enough foundation to build on.

> Source/WebCore/contentextensions/DFA.cpp:43
> +    : m_nodes(nodes)

I think this needs to explicitly move or it will be a copy:
: m_nodes(WTF::move(nodes))

> Source/WebCore/contentextensions/DFA.h:51
> +    Vector<uint64_t> actions(unsigned currentState) const;

This is returning a copy of the Vector, which is probably not what you want.
Comment 6 Benjamin Poulain 2015-01-08 17:55:57 PST
Committed r178151: <http://trac.webkit.org/changeset/178151>