I have a Python program that uses WebKitGTK+ (via
GObject-Introspection) to create a WebView, populate it with an HTML
form, and handle submissions of that form.
After my Python code has handled the submission, I want WebKit to stop
its further processing: it must *not* navigate away to the form's
To accomplish this, I keep references to the submission requests, as
suggested by the docs for the submit-form signal . This works for
me with WebKitGTK+ 2.10 and 2.12.
But with 2.14.2, the WebView "freezes" after my on_submit_form
callback returns. That is, after clicking the "Submit" button, it
stays visually pressed down, and I can no longer scroll the view or
type in the input field. However, if I click the "Submit" button again
in this "frozen" state, my callback is called again and produces the
same output. And if I right-click in the WebView, the context menu
still pops up.
Of course, if I don't keep the reference -- that is, if I remove
"refs.append(request)" -- then the WebView navigates away to the form
target (about:blank), which is what I want to *prevent*.
Any idea why my code breaks with 2.14? Maybe there's a better way to
do what I want?
webkit-gtk mailing list