[SCM] WebKit Debian packaging branch, debian/experimental, updated. upstream/1.3.3-9427-gc2be6fc

kim.1.gronholm at nokia.com kim.1.gronholm at nokia.com
Wed Dec 22 11:32:51 UTC 2010


The following commit has been merged in the debian/experimental branch:
commit 51c81d94322c3c944335864f4fa7aa9227edb6c7
Author: kim.1.gronholm at nokia.com <kim.1.gronholm at nokia.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date:   Wed Jul 28 23:45:53 2010 +0000

    2010-07-28  Kim Grönholm  <kim.1.gronholm at nokia.com>
    
            Reviewed by Antonio Gomes.
    
            [Qt] Decouple QTouchEvent's accepted flag from JS prevent default
            https://bugs.webkit.org/show_bug.cgi?id=42892
    
            Added comments to the touch event handling code.
    
            * Api/qgraphicswebview.cpp:
            (QGraphicsWebView::sceneEvent):
            * Api/qwebpage.cpp:
            (QWebPagePrivate::touchEvent):
            (QWebPage::event):
            * Api/qwebpage_p.h:
            * Api/qwebview.cpp:
            (QWebView::event):
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@64245 268f45cc-cd09-0410-ab3c-d52691b4dbfc

diff --git a/WebKit/qt/Api/qgraphicswebview.cpp b/WebKit/qt/Api/qgraphicswebview.cpp
index 853e637..8a94c9b 100644
--- a/WebKit/qt/Api/qgraphicswebview.cpp
+++ b/WebKit/qt/Api/qgraphicswebview.cpp
@@ -319,6 +319,8 @@ bool QGraphicsWebView::sceneEvent(QEvent* event)
                 || event->type() == QEvent::TouchEnd
                 || event->type() == QEvent::TouchUpdate)) {
         d->page->event(event);
+
+        // Always return true so that we'll receive also TouchUpdate and TouchEnd events
         return true;
     }
 #endif
diff --git a/WebKit/qt/Api/qwebpage.cpp b/WebKit/qt/Api/qwebpage.cpp
index 43eb046..fa49293 100644
--- a/WebKit/qt/Api/qwebpage.cpp
+++ b/WebKit/qt/Api/qwebpage.cpp
@@ -1399,7 +1399,10 @@ bool QWebPagePrivate::touchEvent(QTouchEvent* event)
     if (!frame->view())
         return false;
 
+    // Always accept the QTouchEvent so that we'll receive also TouchUpdate and TouchEnd events
     event->setAccepted(true);
+
+    // Return whether the default action was cancelled in the JS event handler
     return frame->eventHandler()->handleTouchEvent(PlatformTouchEvent(event));
 }
 #endif
@@ -2844,6 +2847,7 @@ bool QWebPage::event(QEvent *ev)
     case QEvent::TouchBegin:
     case QEvent::TouchUpdate:
     case QEvent::TouchEnd:
+        // Return whether the default action was cancelled in the JS event handler
         return d->touchEvent(static_cast<QTouchEvent*>(ev));
 #endif
 #ifndef QT_NO_PROPERTIES
diff --git a/WebKit/qt/Api/qwebpage_p.h b/WebKit/qt/Api/qwebpage_p.h
index 3df2004..44ceb87 100644
--- a/WebKit/qt/Api/qwebpage_p.h
+++ b/WebKit/qt/Api/qwebpage_p.h
@@ -132,6 +132,7 @@ public:
     bool handleScrolling(QKeyEvent*, WebCore::Frame*);
 
 #if QT_VERSION >= QT_VERSION_CHECK(4, 6, 0)
+    // Returns whether the default action was cancelled in the JS event handler
     bool touchEvent(QTouchEvent*);
 #endif
 
diff --git a/WebKit/qt/Api/qwebview.cpp b/WebKit/qt/Api/qwebview.cpp
index 5673326..3daa045 100644
--- a/WebKit/qt/Api/qwebview.cpp
+++ b/WebKit/qt/Api/qwebview.cpp
@@ -826,6 +826,8 @@ bool QWebView::event(QEvent *e)
                    || e->type() == QEvent::TouchEnd 
                    || e->type() == QEvent::TouchUpdate) {
             d->page->event(e);
+
+            // Always return true so that we'll receive also TouchUpdate and TouchEnd events
             return true;
 #endif
         } else if (e->type() == QEvent::Leave)
diff --git a/WebKit/qt/ChangeLog b/WebKit/qt/ChangeLog
index c35e0cf..455fd89 100644
--- a/WebKit/qt/ChangeLog
+++ b/WebKit/qt/ChangeLog
@@ -1,3 +1,21 @@
+2010-07-28  Kim Grönholm  <kim.1.gronholm at nokia.com>
+
+        Reviewed by Antonio Gomes.
+
+        [Qt] Decouple QTouchEvent's accepted flag from JS prevent default
+        https://bugs.webkit.org/show_bug.cgi?id=42892
+
+        Added comments to the touch event handling code.
+
+        * Api/qgraphicswebview.cpp:
+        (QGraphicsWebView::sceneEvent):
+        * Api/qwebpage.cpp:
+        (QWebPagePrivate::touchEvent):
+        (QWebPage::event):
+        * Api/qwebpage_p.h:
+        * Api/qwebview.cpp:
+        (QWebView::event):
+
 2010-07-26  Steve Block  <steveblock at google.com>
 
         Reviewed by Jeremy Orlow.

-- 
WebKit Debian packaging



More information about the Pkg-webkit-commits mailing list