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

commit-queue at webkit.org commit-queue at webkit.org
Wed Dec 22 18:23:39 UTC 2010


The following commit has been merged in the debian/experimental branch:
commit 43894ca9bb289531e1058155e8394b2edb56cfc0
Author: commit-queue at webkit.org <commit-queue at webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date:   Fri Dec 10 12:14:54 2010 +0000

    2010-12-10  Emil Eklund  <eae at chromium.org>
    
            Reviewed by Eric Seidel.
    
            Change EventHandler::dispatchMouseEvent code to use DOM traversal instead of render tree traversal
            https://bugs.webkit.org/show_bug.cgi?id=49982
    
            * page/EventHandler.cpp:
            (WebCore::EventHandler::dispatchMouseEvent):
            Walk up DOM/hosted tree rather than render tree.
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@73717 268f45cc-cd09-0410-ab3c-d52691b4dbfc

diff --git a/WebCore/ChangeLog b/WebCore/ChangeLog
index c31c9e7..1a3bb4a 100644
--- a/WebCore/ChangeLog
+++ b/WebCore/ChangeLog
@@ -1,3 +1,14 @@
+2010-12-10  Emil Eklund  <eae at chromium.org>
+
+        Reviewed by Eric Seidel.
+
+        Change EventHandler::dispatchMouseEvent code to use DOM traversal instead of render tree traversal
+        https://bugs.webkit.org/show_bug.cgi?id=49982
+
+        * page/EventHandler.cpp:
+        (WebCore::EventHandler::dispatchMouseEvent):
+        Walk up DOM/hosted tree rather than render tree.
+
 2010-12-10  Jocelyn Turcotte  <jocelyn.turcotte at nokia.com>
 
         Reviewed by Kenneth Rohde Christiansen.
diff --git a/WebCore/page/EventHandler.cpp b/WebCore/page/EventHandler.cpp
index 328be63..a767849 100644
--- a/WebCore/page/EventHandler.cpp
+++ b/WebCore/page/EventHandler.cpp
@@ -1855,16 +1855,12 @@ bool EventHandler::dispatchMouseEvent(const AtomicString& eventType, Node* targe
         // is expected by some sites that rely on onChange handlers running
         // from form fields before the button click is processed.
         Node* node = m_nodeUnderMouse.get();
-        RenderObject* renderer = node ? node->renderer() : 0;
 
-        // Walk up the render tree to search for a node to focus.
-        // Walking up the DOM tree wouldn't work for shadow trees, like those behind the engine-based text fields.
-        // FIXME: Rework to use shadowParent. No need to traverse with the render tree.
-        while (renderer) {
-            node = renderer->node();
-            if (node && node->isMouseFocusable()) {
-                // To fix <rdar://problem/4895428> Can't drag selected ToDo, we don't focus a 
-                // node on mouse down if it's selected and inside a focused node. It will be 
+        // Walk up the DOM tree to search for a node to focus.
+        while (node) {
+            if (node->isMouseFocusable()) {
+                // To fix <rdar://problem/4895428> Can't drag selected ToDo, we don't focus a
+                // node on mouse down if it's selected and inside a focused node. It will be
                 // focused if the user does a mouseup over it, however, because the mouseup
                 // will set a selection inside it, which will call setFocuseNodeIfNeeded.
                 ExceptionCode ec = 0;
@@ -1876,8 +1872,7 @@ bool EventHandler::dispatchMouseEvent(const AtomicString& eventType, Node* targe
                     
                 break;
             }
-            
-            renderer = renderer->parent();
+            node = node->parentOrHostNode();
         }
 
         // If focus shift is blocked, we eat the event.  Note we should never clear swallowEvent

-- 
WebKit Debian packaging



More information about the Pkg-webkit-commits mailing list