[SCM] WebKit Debian packaging branch, debian/experimental, updated. debian/1.3.8-1-1049-g2e11a8e

dbates at webkit.org dbates at webkit.org
Fri Jan 21 14:49:54 UTC 2011


The following commit has been merged in the debian/experimental branch:
commit 9d7dff1af02f9e53f4b05a18cb3747409a519799
Author: dbates at webkit.org <dbates at webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date:   Sat Jan 1 00:36:20 2011 +0000

    2010-12-31  Daniel Bates  <dbates at rim.com>
    
            Reviewed by Darin Adler.
    
            Pass style for <area> instead of associated <img> when querying whether
            the theme draws the focus ring for an <area>
            https://bugs.webkit.org/show_bug.cgi?id=51632
    
            Fixes an issue where the style for the associated <img> of an <area>
            was passed when considering whether the theme should draw a focus ring
            for the <area>. Instead, we should pass the theme the style for the <area>.
    
            It's not possible to test this at this time since there are no themes
            that override focus ring drawing for <area>s.
    
            * rendering/RenderImage.cpp:
            (WebCore::RenderImage::paintFocusRing): Moved call to RenderTheme::supportsFocusRing()
            such that it's called with respect to the focused <area>.
    
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@74839 268f45cc-cd09-0410-ab3c-d52691b4dbfc

diff --git a/WebCore/ChangeLog b/WebCore/ChangeLog
index 479d9be..1ab9473 100644
--- a/WebCore/ChangeLog
+++ b/WebCore/ChangeLog
@@ -1,3 +1,22 @@
+2010-12-31  Daniel Bates  <dbates at rim.com>
+
+        Reviewed by Darin Adler.
+
+        Pass style for <area> instead of associated <img> when querying whether
+        the theme draws the focus ring for an <area>
+        https://bugs.webkit.org/show_bug.cgi?id=51632
+
+        Fixes an issue where the style for the associated <img> of an <area>
+        was passed when considering whether the theme should draw a focus ring
+        for the <area>. Instead, we should pass the theme the style for the <area>.
+
+        It's not possible to test this at this time since there are no themes
+        that override focus ring drawing for <area>s.
+
+        * rendering/RenderImage.cpp:
+        (WebCore::RenderImage::paintFocusRing): Moved call to RenderTheme::supportsFocusRing()
+        such that it's called with respect to the focused <area>.
+
 2010-12-31  Darin Adler  <darin at apple.com>
 
         * WebCore.xcodeproj/project.pbxproj: Added back the language.
diff --git a/WebCore/rendering/RenderImage.cpp b/WebCore/rendering/RenderImage.cpp
index 609d944..ef2308b 100644
--- a/WebCore/rendering/RenderImage.cpp
+++ b/WebCore/rendering/RenderImage.cpp
@@ -325,7 +325,7 @@ void RenderImage::paint(PaintInfo& paintInfo, int tx, int ty)
         paintFocusRing(paintInfo, style());
 }
     
-void RenderImage::paintFocusRing(PaintInfo& paintInfo, const RenderStyle* style)
+void RenderImage::paintFocusRing(PaintInfo& paintInfo, const RenderStyle*)
 {
     // Don't draw focus rings if printing.
     if (document()->printing() || !frame()->selection()->isFocusedAndActive())
@@ -348,9 +348,6 @@ void RenderImage::paintFocusRing(PaintInfo& paintInfo, const RenderStyle* style)
     
     RefPtr<HTMLCollection> areas = mapElement->areas();
     unsigned numAreas = areas->length();
-
-    if (theme()->supportsFocusRing(style))
-        return; // The theme draws the focus ring.
     
     // FIXME: Clip the paths to the image bounding box.
     for (unsigned k = 0; k < numAreas; ++k) {
@@ -359,6 +356,8 @@ void RenderImage::paintFocusRing(PaintInfo& paintInfo, const RenderStyle* style)
             continue;
 
         RenderStyle* styleToUse = areaElement->computedStyle();
+        if (theme()->supportsFocusRing(styleToUse))
+            return; // The theme draws the focus ring.
         paintInfo.context->drawFocusRing(areaElement->getPath(this), styleToUse->outlineWidth(), styleToUse->outlineOffset(), styleToUse->visitedDependentColor(CSSPropertyOutlineColor));
         break;
     }

-- 
WebKit Debian packaging



More information about the Pkg-webkit-commits mailing list