Title: [100596] trunk/Source/WebKit/gtk
Revision
100596
Author
[email protected]
Date
2011-11-17 03:47:31 -0800 (Thu, 17 Nov 2011)

Log Message

[GTK] ATK API tests failing because of patch for bug 72390
https://bugs.webkit.org/show_bug.cgi?id=72592

Reviewed by Philippe Normand.

* tests/testatk.c:
(testWebkitAtkParentForRootObject): Remove the offending line in
the unit test, which is not actually required to test the new
functionality and causes problems in some scenarios, due to the
lazy creation mechanism of AtkObjects.

* tests/testatkroles.c:
(finish_loading): Reflect that the document frame object is no
longer the root accessibility object (a scroll pane from now on),
but the only child of that one. Thus, skip that root object.

Modified Paths

Diff

Modified: trunk/Source/WebKit/gtk/ChangeLog (100595 => 100596)


--- trunk/Source/WebKit/gtk/ChangeLog	2011-11-17 11:27:39 UTC (rev 100595)
+++ trunk/Source/WebKit/gtk/ChangeLog	2011-11-17 11:47:31 UTC (rev 100596)
@@ -1,3 +1,21 @@
+2011-11-17  Mario Sanchez Prada  <[email protected]>
+
+        [GTK] ATK API tests failing because of patch for bug 72390
+        https://bugs.webkit.org/show_bug.cgi?id=72592
+
+        Reviewed by Philippe Normand.
+
+        * tests/testatk.c:
+        (testWebkitAtkParentForRootObject): Remove the offending line in
+        the unit test, which is not actually required to test the new
+        functionality and causes problems in some scenarios, due to the
+        lazy creation mechanism of AtkObjects.
+
+        * tests/testatkroles.c:
+        (finish_loading): Reflect that the document frame object is no
+        longer the root accessibility object (a scroll pane from now on),
+        but the only child of that one. Thus, skip that root object.
+
 2011-11-16  Mario Sanchez Prada  <[email protected]>
 
         [GTK] Do not hide accessibility root object from AT's

Modified: trunk/Source/WebKit/gtk/tests/testatk.c (100595 => 100596)


--- trunk/Source/WebKit/gtk/tests/testatk.c	2011-11-17 11:27:39 UTC (rev 100595)
+++ trunk/Source/WebKit/gtk/tests/testatk.c	2011-11-17 11:47:31 UTC (rev 100596)
@@ -1625,7 +1625,6 @@
     AtkObject* axBox = gtk_widget_get_accessible (box);
     g_assert(ATK_IS_OBJECT(axBox));
 
-    g_assert_cmpint(atk_object_get_n_accessible_children(axBox), ==, 1);
     AtkObject* axBoxChild = atk_object_ref_accessible_child(axBox, 0);
     g_assert(axBoxChild);
 

Modified: trunk/Source/WebKit/gtk/tests/testatkroles.c (100595 => 100596)


--- trunk/Source/WebKit/gtk/tests/testatkroles.c	2011-11-17 11:27:39 UTC (rev 100595)
+++ trunk/Source/WebKit/gtk/tests/testatkroles.c	2011-11-17 11:47:31 UTC (rev 100596)
@@ -59,9 +59,18 @@
     if (g_main_loop_is_running(fixture->loop))
         g_main_loop_quit(fixture->loop);
 
-    fixture->documentFrame = gtk_widget_get_accessible(fixture->webView);
+    // With the change to support WK2 accessibility, the root object
+    // has changed and it's no longer the document frame, but a scroll
+    // pane containing the document frame as its only child. See the
+    // bug 72390 for more details on this change.
+    // https://bugs.webkit.org/show_bug.cgi?id=72390
+    AtkObject* rootObject = gtk_widget_get_accessible(fixture->webView);
+    fixture->documentFrame = atk_object_ref_accessible_child(rootObject, 0);
     g_assert(fixture->documentFrame);
 
+    // Remove the reference added by ref_accessible_child() and
+    // return, since we don't need to keep that extra ref at all.
+    g_object_unref(fixture->documentFrame);
     return FALSE;
 }
 
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes

Reply via email to