[SCM] WebKit Debian packaging branch, webkit-1.2, updated. upstream/1.1.90-6072-g9a69373

cfleizach at apple.com cfleizach at apple.com
Thu Apr 8 00:40:46 UTC 2010


The following commit has been merged in the webkit-1.2 branch:
commit 1e2b510499d5c0047961f1de2652b41e8145ade9
Author: cfleizach at apple.com <cfleizach at apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date:   Thu Dec 17 19:48:00 2009 +0000

    AX: DRT needs to support URL for accessibility
    https://bugs.webkit.org/show_bug.cgi?id=32666
    
    Reviewed by David Kilzer.
    
    * DumpRenderTree/AccessibilityUIElement.cpp:
    (getURLCallback):
    (AccessibilityUIElement::getJSClass):
    * DumpRenderTree/AccessibilityUIElement.h:
    * DumpRenderTree/gtk/AccessibilityUIElementGtk.cpp:
    (AccessibilityUIElement::url):
    * DumpRenderTree/mac/AccessibilityUIElementMac.mm:
    (AccessibilityUIElement::url):
    * DumpRenderTree/win/AccessibilityUIElementWin.cpp:
    (AccessibilityUIElement::url):
    
    
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@52272 268f45cc-cd09-0410-ab3c-d52691b4dbfc

diff --git a/WebKitTools/ChangeLog b/WebKitTools/ChangeLog
index 699fd88..6a2dc9e 100644
--- a/WebKitTools/ChangeLog
+++ b/WebKitTools/ChangeLog
@@ -1,3 +1,21 @@
+2009-12-17  Chris Fleizach  <cfleizach at apple.com>
+
+        Reviewed by David Kilzer.
+
+        AX: DRT needs to support URL for accessibility
+        https://bugs.webkit.org/show_bug.cgi?id=32666
+
+        * DumpRenderTree/AccessibilityUIElement.cpp:
+        (getURLCallback):
+        (AccessibilityUIElement::getJSClass):
+        * DumpRenderTree/AccessibilityUIElement.h:
+        * DumpRenderTree/gtk/AccessibilityUIElementGtk.cpp:
+        (AccessibilityUIElement::url):
+        * DumpRenderTree/mac/AccessibilityUIElementMac.mm:
+        (AccessibilityUIElement::url):
+        * DumpRenderTree/win/AccessibilityUIElementWin.cpp:
+        (AccessibilityUIElement::url):
+
 2009-12-17  Philippe Normand  <pnormand at igalia.com>
 
         Unreviewed; added myself to committers
diff --git a/WebKitTools/DumpRenderTree/AccessibilityUIElement.cpp b/WebKitTools/DumpRenderTree/AccessibilityUIElement.cpp
index 8c59252..634c2f3 100644
--- a/WebKitTools/DumpRenderTree/AccessibilityUIElement.cpp
+++ b/WebKitTools/DumpRenderTree/AccessibilityUIElement.cpp
@@ -504,6 +504,12 @@ static JSValueRef getDocumentURICallback(JSContextRef context, JSObjectRef thisO
     return JSValueMakeString(context, documentURI.get());
 }
 
+static JSValueRef getURLCallback(JSContextRef context, JSObjectRef thisObject, JSStringRef propertyName, JSValueRef* exception)
+{
+    JSRetainPtr<JSStringRef> url(Adopt, toAXElement(thisObject)->url());
+    return JSValueMakeString(context, url.get());
+}
+
 // Destruction
 
 static void finalize(JSObjectRef thisObject)
@@ -549,6 +555,7 @@ JSClassRef AccessibilityUIElement::getJSClass()
         { "hierarchicalLevel", hierarchicalLevelCallback, 0, kJSPropertyAttributeReadOnly | kJSPropertyAttributeDontDelete },
         { "documentEncoding", getDocumentEncodingCallback, 0, kJSPropertyAttributeReadOnly | kJSPropertyAttributeDontDelete },
         { "documentURI", getDocumentURICallback, 0, kJSPropertyAttributeReadOnly | kJSPropertyAttributeDontDelete },
+        { "url", getURLCallback, 0, kJSPropertyAttributeReadOnly | kJSPropertyAttributeDontDelete },
         { "isValid", getIsValidCallback, 0, kJSPropertyAttributeReadOnly | kJSPropertyAttributeDontDelete },
         { "orientation", getOrientationCallback, 0, kJSPropertyAttributeReadOnly | kJSPropertyAttributeDontDelete },
         { "ariaIsGrabbed", getARIAIsGrabbedCallback, 0, kJSPropertyAttributeReadOnly | kJSPropertyAttributeDontDelete },
diff --git a/WebKitTools/DumpRenderTree/AccessibilityUIElement.h b/WebKitTools/DumpRenderTree/AccessibilityUIElement.h
index 9985523..7105ea8 100644
--- a/WebKitTools/DumpRenderTree/AccessibilityUIElement.h
+++ b/WebKitTools/DumpRenderTree/AccessibilityUIElement.h
@@ -117,6 +117,7 @@ public:
     double clickPointY();
     JSStringRef documentEncoding();
     JSStringRef documentURI();
+    JSStringRef url();
 
     // Table-specific attributes
     JSStringRef attributesOfColumnHeaders();
diff --git a/WebKitTools/DumpRenderTree/gtk/AccessibilityUIElementGtk.cpp b/WebKitTools/DumpRenderTree/gtk/AccessibilityUIElementGtk.cpp
index 13d313d..3ff7810 100644
--- a/WebKitTools/DumpRenderTree/gtk/AccessibilityUIElementGtk.cpp
+++ b/WebKitTools/DumpRenderTree/gtk/AccessibilityUIElementGtk.cpp
@@ -528,3 +528,9 @@ JSStringRef AccessibilityUIElement::documentURI()
 
     return JSStringCreateWithUTF8CString(atk_document_get_attribute_value(ATK_DOCUMENT(m_element), "URI"));
 }
+
+JSStringRef AccessibilityUIElement::url()
+{
+    // FIXME: implement
+    return JSStringCreateWithCharacters(0, 0);
+}
diff --git a/WebKitTools/DumpRenderTree/mac/AccessibilityUIElementMac.mm b/WebKitTools/DumpRenderTree/mac/AccessibilityUIElementMac.mm
index 948f379..2e96280 100644
--- a/WebKitTools/DumpRenderTree/mac/AccessibilityUIElementMac.mm
+++ b/WebKitTools/DumpRenderTree/mac/AccessibilityUIElementMac.mm
@@ -721,3 +721,9 @@ JSStringRef AccessibilityUIElement::documentURI()
 {
     return JSStringCreateWithCharacters(0, 0);
 }
+
+JSStringRef AccessibilityUIElement::url()
+{
+    NSURL *url = [m_element accessibilityAttributeValue:NSAccessibilityURLAttribute];
+    return [[url absoluteString] createJSStringRef];    
+}
diff --git a/WebKitTools/DumpRenderTree/win/AccessibilityUIElementWin.cpp b/WebKitTools/DumpRenderTree/win/AccessibilityUIElementWin.cpp
index 163abb1..cce24c0 100644
--- a/WebKitTools/DumpRenderTree/win/AccessibilityUIElementWin.cpp
+++ b/WebKitTools/DumpRenderTree/win/AccessibilityUIElementWin.cpp
@@ -477,3 +477,10 @@ JSStringRef AccessibilityUIElement::documentURI()
 {
     return JSStringCreateWithCharacters(0, 0);
 }
+
+JSStringRef AccessibilityUIElement::url()
+{
+    // FIXME: implement
+    return JSStringCreateWithCharacters(0, 0);
+}
+

-- 
WebKit Debian packaging



More information about the Pkg-webkit-commits mailing list