[SCM] WebKit Debian packaging branch, debian/experimental, updated. upstream/1.3.3-9427-gc2be6fc
hausmann at webkit.org
hausmann at webkit.org
Wed Dec 22 13:21:34 UTC 2010
The following commit has been merged in the debian/experimental branch:
commit 5222464e41fa438d7f27f61e30025f03f6227567
Author: hausmann at webkit.org <hausmann at webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date: Sun Sep 12 20:58:30 2010 +0000
[Qml] Ensure WebView gets focus when an editable node is clicked on.
Patch by Martin Jones <martin.jones at nokia.com> on 2010-09-12
Reviewed by Simon Hausmann.
Task-number: QTBUG-13342
* declarative/qdeclarativewebview.cpp:
(GraphicsWebView::mousePressEvent):
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@67346 268f45cc-cd09-0410-ab3c-d52691b4dbfc
diff --git a/WebKit/qt/ChangeLog b/WebKit/qt/ChangeLog
index 1ef774a..f22689f 100644
--- a/WebKit/qt/ChangeLog
+++ b/WebKit/qt/ChangeLog
@@ -1,3 +1,14 @@
+2010-09-12 Martin Jones <martin.jones at nokia.com>
+
+ Reviewed by Simon Hausmann.
+
+ [Qml] Ensure WebView gets focus when an editable node is clicked on.
+
+ Task-number: QTBUG-13342
+
+ * declarative/qdeclarativewebview.cpp:
+ (GraphicsWebView::mousePressEvent):
+
2010-09-12 David Boddie <david.boddie at nokia.com>
Reviewed by Simon Hausmann.
diff --git a/WebKit/qt/declarative/qdeclarativewebview.cpp b/WebKit/qt/declarative/qdeclarativewebview.cpp
index 1538133..65cbedf 100644
--- a/WebKit/qt/declarative/qdeclarativewebview.cpp
+++ b/WebKit/qt/declarative/qdeclarativewebview.cpp
@@ -91,7 +91,6 @@ GraphicsWebView::GraphicsWebView(QDeclarativeWebView* parent)
void GraphicsWebView::mousePressEvent(QGraphicsSceneMouseEvent* event)
{
- setFocus();
pressPoint = event->pos();
if (pressTime) {
pressTimer.start(pressTime, this);
@@ -101,6 +100,11 @@ void GraphicsWebView::mousePressEvent(QGraphicsSceneMouseEvent* event)
parent->setKeepMouseGrab(true);
}
QGraphicsWebView::mousePressEvent(event);
+
+ QWebHitTestResult hit = page()->mainFrame()->hitTestContent(pressPoint.toPoint());
+ if (hit.isContentEditable())
+ parent->forceActiveFocus();
+ setFocus();
}
void GraphicsWebView::mouseReleaseEvent(QGraphicsSceneMouseEvent* event)
--
WebKit Debian packaging
More information about the Pkg-webkit-commits
mailing list