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

eric at webkit.org eric at webkit.org
Thu Oct 29 20:46:56 UTC 2009


The following commit has been merged in the webkit-1.1 branch:
commit 84496199b518f5f9fe30944895a6517699a7adce
Author: eric at webkit.org <eric at webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date:   Sat Oct 17 20:00:33 2009 +0000

    2009-10-17  Joanmarie Diggs  <joanmarie.diggs at gmail.com>
    
            Reviewed by Xan Lopez.
    
            https://bugs.webkit.org/show_bug.cgi?id=25413
            [GTK] Please expose the level of headings
    
            Exposes the heading level as an attribute of the AtkObject.
    
            * accessibility/gtk/AccessibilityObjectWrapperAtk.cpp:
            (addAttributeToSet):
            (webkit_accessible_get_attributes):
            (webkit_accessible_class_init):
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@49743 268f45cc-cd09-0410-ab3c-d52691b4dbfc

diff --git a/WebCore/ChangeLog b/WebCore/ChangeLog
index cfd249e..0aa2ad8 100644
--- a/WebCore/ChangeLog
+++ b/WebCore/ChangeLog
@@ -1,3 +1,17 @@
+2009-10-17  Joanmarie Diggs  <joanmarie.diggs at gmail.com>
+
+        Reviewed by Xan Lopez.
+
+        https://bugs.webkit.org/show_bug.cgi?id=25413
+        [GTK] Please expose the level of headings
+
+        Exposes the heading level as an attribute of the AtkObject.
+
+        * accessibility/gtk/AccessibilityObjectWrapperAtk.cpp:
+        (addAttributeToSet):
+        (webkit_accessible_get_attributes):
+        (webkit_accessible_class_init):
+
 2009-10-17  Kwang Yul Seo  <skyul at company100.net>
 
         Reviewed by Eric Seidel.
diff --git a/WebCore/accessibility/gtk/AccessibilityObjectWrapperAtk.cpp b/WebCore/accessibility/gtk/AccessibilityObjectWrapperAtk.cpp
index 811903d..0ec073b 100644
--- a/WebCore/accessibility/gtk/AccessibilityObjectWrapperAtk.cpp
+++ b/WebCore/accessibility/gtk/AccessibilityObjectWrapperAtk.cpp
@@ -174,6 +174,28 @@ static gint webkit_accessible_get_index_in_parent(AtkObject* object)
     return 0;
 }
 
+static AtkAttributeSet* addAttributeToSet(AtkAttributeSet* attributeSet, const char* name, const char* value)
+{
+    AtkAttribute* attribute = static_cast<AtkAttribute*>(g_malloc(sizeof(AtkAttribute)));
+    attribute->name = g_strdup(name);
+    attribute->value = g_strdup(value);
+    attributeSet = g_slist_prepend(attributeSet, attribute);
+
+    return attributeSet;
+}
+
+static AtkAttributeSet* webkit_accessible_get_attributes(AtkObject* object)
+{
+    AtkAttributeSet* attributeSet = NULL;
+
+    int headingLevel = core(object)->headingLevel();
+    if (headingLevel) {
+        String value = String::number(headingLevel);
+        attributeSet = addAttributeToSet(attributeSet, "level", value.utf8().data());
+    }
+    return attributeSet;
+}
+
 static AtkRole atkRole(AccessibilityRole role)
 {
     switch (role) {
@@ -408,6 +430,7 @@ static void webkit_accessible_class_init(AtkObjectClass* klass)
     klass->get_role = webkit_accessible_get_role;
     klass->ref_state_set = webkit_accessible_ref_state_set;
     klass->get_index_in_parent = webkit_accessible_get_index_in_parent;
+    klass->get_attributes = webkit_accessible_get_attributes;
 }
 
 GType

-- 
WebKit Debian packaging



More information about the Pkg-webkit-commits mailing list