Hello, Quoting Robert Schroll (2014-10-16 19:01:40)
On Thu, Oct 16, 2014 at 9:53 AM, Adrian Perez de Castro <aperez igalia com> wrote:As a matter of fact, I have an almost-ready patch to allow to send messages from JavaScript (in the web process) to the UI process [1]. That, along with the recently-added support for script injection [2] will make it much easier to solve the inter-process communication for a lot of use cases.This would be great. If you let me know when this makes it into WebKitGTK, I'll update the example to use it.
This is now in the 2.7.x versions. You can check the documentation here: http://webkitgtk.org/reference/webkit2gtk/unstable/WebKitUserContentManager.html#webkit-user-content-manager-register-script-message-handler The API is not expected to change, but as usual if you want to be sure that it won't change you can wait until the 2.8.0 stable release. Carlos García has been already updating Epiphany here and there to use the script message handlers, and it is allowing to make the code simpler. For example: https://git.gnome.org/browse/epiphany/commit/?id=865735b61b0f29285f8769423d6c25dbcdfa50ca https://git.gnome.org/browse/epiphany/commit/?id=d6dbc20b01eacccdf419916a13cf0ec18b43951d https://git.gnome.org/browse/epiphany/commit/?id=701b6a959b4aaeff49941e88101f82159a76655f Best regards, -- ☺ Adrián
Attachment:
signature.asc
Description: signature