Bug 129030 - [WK2] IPC callback classes should not be tightly coupled to C API
Summary: [WK2] IPC callback classes should not be tightly coupled to C API
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebKit2 (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Alexey Proskuryakov
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-02-18 23:10 PST by Alexey Proskuryakov
Modified: 2014-02-19 19:16 PST (History)
11 users (show)

See Also:


Attachments
proposed patch (84.64 KB, patch)
2014-02-18 23:18 PST, Alexey Proskuryakov
no flags Details | Formatted Diff | Diff
proposed patch (83.90 KB, patch)
2014-02-18 23:38 PST, Alexey Proskuryakov
andersca: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
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>.