Bug 129030

Summary: [WK2] IPC callback classes should not be tightly coupled to C API
Product: WebKit Reporter: Alexey Proskuryakov <ap>
Component: WebKit2Assignee: Alexey Proskuryakov <ap>
Status: RESOLVED FIXED    
Severity: Normal CC: andersca, berto, cgarcia, commit-queue, eric.carlson, glenn, gustavo, jer.noble, mrobinson, philipj, sergio
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
proposed patch
none
proposed patch andersca: review+

Description Alexey Proskuryakov 2014-02-18 23:10:34 PST
Currently, CallbackBase subclasses call result functions with C API objects as arguments.

This causes very roundabout code in cases where we provide the results to Objective C or Gtk APIs - we first create C API objects, and then unwrap them.
Comment 1 Alexey Proskuryakov 2014-02-18 23:18:28 PST
Created attachment 224598 [details]
proposed patch
Comment 2 WebKit Commit Bot 2014-02-18 23:20:34 PST
Thanks for the patch. If this patch contains new public API please make sure it follows the guidelines for new WebKit2 GTK+ API. See http://trac.webkit.org/wiki/WebKitGTK/AddingNewWebKit2API
Comment 3 Alexey Proskuryakov 2014-02-18 23:38:34 PST
Created attachment 224599 [details]
proposed patch
Comment 4 Anders Carlsson 2014-02-19 16:42:10 PST
Comment on attachment 224599 [details]
proposed patch

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

> Source/WebKit2/UIProcess/WebPageProxy.h:233
> +    typedef std::function<void(bool, const WebCore::IntPoint&, uint32_t, uint32_t, uint32_t)> CallbackFunction;

Missing space between void and (
Comment 5 Alexey Proskuryakov 2014-02-19 19:16:31 PST
Committed <http://trac.webkit.org/r164409>.