[SCM] WebKit Debian packaging branch, webkit-1.1, updated. upstream/1.1.15.1-1414-gc69ee75

tonikitoo at webkit.org tonikitoo at webkit.org
Thu Oct 29 20:45:11 UTC 2009


The following commit has been merged in the webkit-1.1 branch:
commit a1d915144e6b6581c723ed684e4b07158f1d85e5
Author: tonikitoo at webkit.org <tonikitoo at webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date:   Thu Oct 15 12:41:30 2009 +0000

    [Qt] Make context menu to work in QGraphicsWebView
    https://bugs.webkit.org/show_bug.cgi?id=30336
    
    Patch by Antonio Gomes <tonikitoo at webkit.org> on 2009-10-13
    Reviewed by Simon Hausmann.
    
    * Api/qgraphicswebview.cpp:
    (QGraphicsWebView::event):
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@49618 268f45cc-cd09-0410-ab3c-d52691b4dbfc

diff --git a/WebKit/qt/Api/qgraphicswebview.cpp b/WebKit/qt/Api/qgraphicswebview.cpp
index 1e49d3e..7599d88 100644
--- a/WebKit/qt/Api/qgraphicswebview.cpp
+++ b/WebKit/qt/Api/qgraphicswebview.cpp
@@ -249,6 +249,20 @@ bool QGraphicsWebView::event(QEvent* event)
     // Re-implemented in order to allows fixing event-related bugs in patch releases.
 
     if (d->page) {
+#ifndef QT_NO_CONTEXTMENU
+        if (event->type() == QEvent::GraphicsSceneContextMenu) {
+            if (!isEnabled())
+                return false;
+
+            QGraphicsSceneContextMenuEvent* ev = static_cast<QGraphicsSceneContextMenuEvent*>(event);
+            QContextMenuEvent fakeEvent(QContextMenuEvent::Reason(ev->reason()), ev->pos().toPoint());
+            if (d->page->swallowContextMenuEvent(&fakeEvent)) {
+                event->accept();
+                return true;
+            }
+            d->page->updatePositionDependentActions(fakeEvent.pos());
+        }
+#endif // QT_NO_CONTEXTMENU
 #ifndef QT_NO_CURSOR
 #if QT_VERSION >= 0x040400
         } else if (event->type() == QEvent::CursorChange) {
diff --git a/WebKit/qt/ChangeLog b/WebKit/qt/ChangeLog
index 44821b4..a536c3f 100644
--- a/WebKit/qt/ChangeLog
+++ b/WebKit/qt/ChangeLog
@@ -1,3 +1,13 @@
+2009-10-13  Antonio Gomes  <tonikitoo at webkit.org>
+
+        Reviewed by Simon Hausmann.
+
+        [Qt] Make context menu to work in QGraphicsWebView
+        https://bugs.webkit.org/show_bug.cgi?id=30336
+
+        * Api/qgraphicswebview.cpp:
+        (QGraphicsWebView::event):
+
 2009-10-13  Girish Ramakrishnan  <girish at forwardbias.in>
 
         Reviewed by Simon Hausmann.

-- 
WebKit Debian packaging



More information about the Pkg-webkit-commits mailing list