summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorQt Continuous Integration System <qt-info@nokia.com>2010-07-27 15:50:45 (GMT)
committerQt Continuous Integration System <qt-info@nokia.com>2010-07-27 15:50:45 (GMT)
commitdd69f111cdcd0764770717dec30a08f353dbef07 (patch)
tree860183de8314d84cabccf8b4c736bef1179db357 /src
parentc21b143c58b22ed564b04bd79b1b17776cf306e2 (diff)
parentbe1e08209a1cef9ff15fc5cc49d4d1d611d917cb (diff)
downloadQt-dd69f111cdcd0764770717dec30a08f353dbef07.zip
Qt-dd69f111cdcd0764770717dec30a08f353dbef07.tar.gz
Qt-dd69f111cdcd0764770717dec30a08f353dbef07.tar.bz2
Merge branch '4.6' of scm.dev.nokia.troll.no:qt/oslo-staging-1 into 4.6-integration
* '4.6' of scm.dev.nokia.troll.no:qt/oslo-staging-1: Updated WebKit from /home/shausman/src/webkit/trunk to qtwebkit/qtwebkit-4.6 ( d521d7d81e8f0297c94be9ebd8af67ee130d0edb )
Diffstat (limited to 'src')
-rw-r--r--src/3rdparty/webkit/VERSION2
-rw-r--r--src/3rdparty/webkit/WebKit/qt/ChangeLog16
-rw-r--r--src/3rdparty/webkit/WebKit/qt/WebCoreSupport/EditorClientQt.cpp26
-rw-r--r--src/3rdparty/webkit/WebKit/qt/tests/qwebview/tst_qwebview.cpp23
4 files changed, 47 insertions, 20 deletions
diff --git a/src/3rdparty/webkit/VERSION b/src/3rdparty/webkit/VERSION
index b6178b9..358024b 100644
--- a/src/3rdparty/webkit/VERSION
+++ b/src/3rdparty/webkit/VERSION
@@ -8,4 +8,4 @@ The commit imported was from the
and has the sha1 checksum
- 038b62085831eef4dee423361c65ecd55b7b9b1d
+ d521d7d81e8f0297c94be9ebd8af67ee130d0edb
diff --git a/src/3rdparty/webkit/WebKit/qt/ChangeLog b/src/3rdparty/webkit/WebKit/qt/ChangeLog
index cf335a1..7d419d5 100644
--- a/src/3rdparty/webkit/WebKit/qt/ChangeLog
+++ b/src/3rdparty/webkit/WebKit/qt/ChangeLog
@@ -1,3 +1,19 @@
+2010-07-27 Simon Hausmann <simon.hausmann@nokia.com>
+
+ Reviewed by Tor Arne Vestbø.
+
+ [Qt] Incorrect input method hints
+ https://bugs.webkit.org/show_bug.cgi?id=43037
+
+ Properly set or reset all input method hints when
+ activating input fields.
+
+ * WebCoreSupport/EditorClientQt.cpp:
+ (WebCore::EditorClientQt::setInputMethodState):
+ * tests/qwebview/tst_qwebview.cpp:
+ (tst_QWebView::focusInputTypes): Extended unit test to verify that we
+ reset hints.
+
2010-06-18 Simon Hausmann <simon.hausmann@nokia.com>
Reviewed by Antti Koivisto.
diff --git a/src/3rdparty/webkit/WebKit/qt/WebCoreSupport/EditorClientQt.cpp b/src/3rdparty/webkit/WebKit/qt/WebCoreSupport/EditorClientQt.cpp
index 3255c8e..cb0758b 100644
--- a/src/3rdparty/webkit/WebKit/qt/WebCoreSupport/EditorClientQt.cpp
+++ b/src/3rdparty/webkit/WebKit/qt/WebCoreSupport/EditorClientQt.cpp
@@ -608,20 +608,18 @@ void EditorClientQt::setInputMethodState(bool active)
inputElement = static_cast<HTMLInputElement*>(frame->document()->focusedNode());
if (inputElement) {
- if (!active) {
- // Setting the Qt::WA_InputMethodEnabled attribute true and Qt::ImhHiddenText flag
- // for password fields. The Qt platform is responsible for determining which widget
- // will receive input method events for password fields.
- active = inputElement->isPasswordField();
- webPageClient->setInputMethodHint(Qt::ImhHiddenText, active);
- } else {
- // Set input method hints for "number", "tel", "email", and "url" input elements.
- webPageClient->setInputMethodHint(Qt::ImhDialableCharactersOnly, inputElement->isTelephoneField());
- webPageClient->setInputMethodHint(Qt::ImhDigitsOnly, inputElement->isNumberField());
- webPageClient->setInputMethodHint(Qt::ImhEmailCharactersOnly, inputElement->isEmailField());
- webPageClient->setInputMethodHint(Qt::ImhUrlCharactersOnly, inputElement->isUrlField());
- webPageClient->setInputMethodHint(Qt::ImhHiddenText, inputElement->isPasswordField());
- }
+ // Set input method hints for "number", "tel", "email", "url" and "password" input elements.
+ webPageClient->setInputMethodHint(Qt::ImhDialableCharactersOnly, inputElement->isTelephoneField());
+ webPageClient->setInputMethodHint(Qt::ImhDigitsOnly, inputElement->isNumberField());
+ webPageClient->setInputMethodHint(Qt::ImhEmailCharactersOnly, inputElement->isEmailField());
+ webPageClient->setInputMethodHint(Qt::ImhUrlCharactersOnly, inputElement->isUrlField());
+ // Setting the Qt::WA_InputMethodEnabled attribute true and Qt::ImhHiddenText flag
+ // for password fields. The Qt platform is responsible for determining which widget
+ // will receive input method events for password fields.
+ bool isPasswordField = inputElement->isPasswordField();
+ webPageClient->setInputMethodHint(Qt::ImhHiddenText, isPasswordField);
+ if (isPasswordField)
+ active = true;
}
#if defined(Q_WS_MAEMO_5) || defined(Q_OS_SYMBIAN)
diff --git a/src/3rdparty/webkit/WebKit/qt/tests/qwebview/tst_qwebview.cpp b/src/3rdparty/webkit/WebKit/qt/tests/qwebview/tst_qwebview.cpp
index 5e8e8a9..facee59 100644
--- a/src/3rdparty/webkit/WebKit/qt/tests/qwebview/tst_qwebview.cpp
+++ b/src/3rdparty/webkit/WebKit/qt/tests/qwebview/tst_qwebview.cpp
@@ -254,23 +254,36 @@ void tst_QWebView::focusInputTypes()
// 'password' field
webView->fireMouseClick(QPoint(20, 60));
- QVERIFY(webView->inputMethodHints() & Qt::ImhHiddenText);
+ QVERIFY(webView->inputMethodHints() == Qt::ImhHiddenText);
// 'tel' field
webView->fireMouseClick(QPoint(20, 110));
- QVERIFY(webView->inputMethodHints() & Qt::ImhDialableCharactersOnly);
+ QVERIFY(webView->inputMethodHints() == Qt::ImhDialableCharactersOnly);
// 'number' field
webView->fireMouseClick(QPoint(20, 160));
- QVERIFY(webView->inputMethodHints() & Qt::ImhDigitsOnly);
+ QVERIFY(webView->inputMethodHints() == Qt::ImhDigitsOnly);
// 'email' field
webView->fireMouseClick(QPoint(20, 210));
- QVERIFY(webView->inputMethodHints() & Qt::ImhEmailCharactersOnly);
+ QVERIFY(webView->inputMethodHints() == Qt::ImhEmailCharactersOnly);
// 'url' field
webView->fireMouseClick(QPoint(20, 260));
- QVERIFY(webView->inputMethodHints() & Qt::ImhUrlCharactersOnly);
+ QVERIFY(webView->inputMethodHints() == Qt::ImhUrlCharactersOnly);
+
+ // 'password' field
+ webView->fireMouseClick(QPoint(20, 60));
+ QVERIFY(webView->inputMethodHints() == Qt::ImhHiddenText);
+
+ // 'text' type
+ webView->fireMouseClick(QPoint(20, 10));
+#if defined(Q_WS_MAEMO_5) || defined(Q_WS_MAEMO_6) || defined(Q_OS_SYMBIAN)
+ QVERIFY(webView->inputMethodHints() & Qt::ImhNoAutoUppercase);
+ QVERIFY(webView->inputMethodHints() & Qt::ImhNoPredictiveText);
+#else
+ QVERIFY(webView->inputMethodHints() == Qt::ImhNone);
+#endif
delete webView;