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

mrobinson at webkit.org mrobinson at webkit.org
Wed Dec 22 14:46:21 UTC 2010


The following commit has been merged in the debian/experimental branch:
commit 519a0dca184046ff2a0f538c7efff8a35d4d7c8e
Author: mrobinson at webkit.org <mrobinson at webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date:   Tue Oct 19 21:38:45 2010 +0000

    2010-10-19  Martin Robinson  <mrobinson at igalia.com>
    
            Fix the GTK+ build after r70072. The logic looks incorrect, but
            this fix tries to preserves it, even so.
    
            * accessibility/gtk/AccessibilityObjectWrapperAtk.cpp:
            (baselinePositionForAccessibilityRenderObject):
            (getAttributeSetForAccessibilityObject):
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@70089 268f45cc-cd09-0410-ab3c-d52691b4dbfc

diff --git a/WebCore/ChangeLog b/WebCore/ChangeLog
index 46e0961..1f46aa6 100644
--- a/WebCore/ChangeLog
+++ b/WebCore/ChangeLog
@@ -1,3 +1,12 @@
+2010-10-19  Martin Robinson  <mrobinson at igalia.com>
+
+        Fix the GTK+ build after r70072. The logic looks incorrect, but
+        this fix tries to preserves it, even so.
+
+        * accessibility/gtk/AccessibilityObjectWrapperAtk.cpp:
+        (baselinePositionForAccessibilityRenderObject):
+        (getAttributeSetForAccessibilityObject):
+
 2010-10-06  Jer Noble  <jer.noble at apple.com>
 
         Reviewed by Eric Carlson.
diff --git a/WebCore/accessibility/gtk/AccessibilityObjectWrapperAtk.cpp b/WebCore/accessibility/gtk/AccessibilityObjectWrapperAtk.cpp
index c9d13cc..aa88217 100644
--- a/WebCore/accessibility/gtk/AccessibilityObjectWrapperAtk.cpp
+++ b/WebCore/accessibility/gtk/AccessibilityObjectWrapperAtk.cpp
@@ -1039,6 +1039,15 @@ static gint webkit_accessible_text_get_caret_offset(AtkText* text)
     return offset;
 }
 
+static int baselinePositionForAccessibilityRenderObject(RenderObject* renderObject)
+{
+    // FIXME: This implementation of baselinePosition originates from RenderObject.cpp and was
+    // removed in r70072. The implementation looks incorrect though, because this is not the
+    // baseline of the underlying RenderObject, but of the AccessibilityRenderObject.
+    const Font& f = renderObject->firstLineStyle()->font();
+    return f.ascent() + (renderObject->firstLineStyle()->computedLineHeight() - f.height()) / 2;
+}
+
 static AtkAttributeSet* getAttributeSetForAccessibilityObject(const AccessibilityObject* object)
 {
     if (!object->isAccessibilityRenderObject())
@@ -1069,10 +1078,10 @@ static AtkAttributeSet* getAttributeSetForAccessibilityObject(const Accessibilit
     bool includeRise = true;
     switch (style->verticalAlign()) {
     case SUB:
-        baselinePosition = -1 * renderer->baselinePosition(true);
+        baselinePosition = -1 * baselinePositionForAccessibilityRenderObject(renderer);
         break;
     case SUPER:
-        baselinePosition = renderer->baselinePosition(true);
+        baselinePosition = baselinePositionForAccessibilityRenderObject(renderer);
         break;
     case BASELINE:
         baselinePosition = 0;

-- 
WebKit Debian packaging



More information about the Pkg-webkit-commits mailing list