Bug 85350 - [Qt] QQuickWebView does not allow for input from virtual keyboard
Summary: [Qt] QQuickWebView does not allow for input from virtual keyboard
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: New Bugs (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Simon Hausmann
URL:
Keywords:
: 82736 (view as bug list)
Depends on:
Blocks:
 
Reported: 2012-05-02 00:51 PDT by Simon Hausmann
Modified: 2012-06-02 00:17 PDT (History)
7 users (show)

See Also:


Attachments
Patch (6.57 KB, patch)
2012-05-02 00:54 PDT, Simon Hausmann
no flags Details | Formatted Diff | Diff
Patch (6.59 KB, patch)
2012-05-02 01:06 PDT, Simon Hausmann
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Simon Hausmann 2012-05-02 00:51:08 PDT
[Qt] QQuickWebView does not allow for input from virtual keyboard
Comment 1 Simon Hausmann 2012-05-02 00:52:13 PDT
As Michael analyzed correctly, the issue is that QQuickWebView never sets the ItemAcceptsInputMethod flag correctly, which leads the input method to believe that the item doesn't accept input method events at all.
Comment 2 Simon Hausmann 2012-05-02 00:54:52 PDT
Created attachment 139761 [details]
Patch
Comment 3 Kenneth Rohde Christiansen 2012-05-02 01:03:04 PDT
Comment on attachment 139761 [details]
Patch

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

> Source/WebKit2/UIProcess/API/qt/qquickwebview.cpp:1618
> +void QQuickWebView::runJavaScriptInMainFrame(const QString &script, QObject *receiver, const char *method)

I saw that BB10 Cascades added a similar method, could you verify that we are using more or less the same API for this?
Comment 4 Simon Hausmann 2012-05-02 01:06:03 PDT
Created attachment 139763 [details]
Patch

Rebased
Comment 5 Simon Hausmann 2012-05-02 01:07:59 PDT
Comment on attachment 139761 [details]
Patch

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

>> Source/WebKit2/UIProcess/API/qt/qquickwebview.cpp:1618
>> +void QQuickWebView::runJavaScriptInMainFrame(const QString &script, QObject *receiver, const char *method)
> 
> I saw that BB10 Cascades added a similar method, could you verify that we are using more or less the same API for this?

Hmm, this isn't public API though, just private for testing. I think a more JavaScript style API for this would be much better, along the lines of:

webView.runJavaScript("script here", function(result) {
   ...
})
Comment 6 Simon Hausmann 2012-05-02 01:08:24 PDT
Comment on attachment 139763 [details]
Patch

Oops, clear this. Kenneth r+'ed the earlier patch, will land rebase right away.
Comment 7 Simon Hausmann 2012-05-02 01:10:55 PDT
Committed r115801: <http://trac.webkit.org/changeset/115801>
Comment 8 Lauro Moura Maranhao Neto 2012-05-02 12:56:27 PDT
After r115831 WebKit on N9 still has some problems regarding vkb.

Here's the steps:

- Go to www.google.com
- Search something (vkb works fine)
- On the search result page, tap the input field.
- VKB does not shows, even after returning to the main page.
Comment 9 Simon Hausmann 2012-06-02 00:17:06 PDT
*** Bug 82736 has been marked as a duplicate of this bug. ***