On Wed, Jan 25 2023 at 06:37:11 PM +0100, Antonio <anto...@vieiro.net>
wrote:
The fact is that I'm trying to receive messages from a <script> in my
webpage through the "window.webkit.messageHandlers.XYZ.postMessage()"
call, as indicated in [1], but "window.webkit" is undefined.
I think it's only going to be defined for JS executed via WebKit API,
not for JS that's defined by your web content? Otherwise random web
content would be able to talk to your internal message handlers, and
that's probably not good.
Try webkit_web_view_run_javascript() in the UI process, or
jsc_value_object_invoke_method() in the web process.
Michael
_______________________________________________
webkit-gtk mailing list
webkit-gtk@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-gtk