Diff
Modified: branches/safari-600.5-branch/LayoutTests/ChangeLog (179516 => 179517)
--- branches/safari-600.5-branch/LayoutTests/ChangeLog 2015-02-03 00:57:30 UTC (rev 179516)
+++ branches/safari-600.5-branch/LayoutTests/ChangeLog 2015-02-03 00:57:35 UTC (rev 179517)
@@ -1,5 +1,21 @@
2015-01-20 Babak Shafiei <bshaf...@apple.com>
+ Merge r174741.
+
+ 2014-10-13 Chris Fleizach <cfleiz...@apple.com>
+
+ AX: Going back is broken for VoiceOver
+ https://bugs.webkit.org/show_bug.cgi?id=137382
+
+ Reviewed by Darin Adler.
+
+ Update tests now that AXLoadComplete is sent more reliably.
+
+ * platform/mac/accessibility/aria-expanded-notifications-expected.txt:
+ * platform/mac/accessibility/aria-expanded-notifications.html:
+
+2015-01-20 Babak Shafiei <bshaf...@apple.com>
+
Merge r174712.
2014-10-14 Dan Bernstein <m...@apple.com>
Modified: branches/safari-600.5-branch/LayoutTests/platform/mac/accessibility/aria-expanded-notifications-expected.txt (179516 => 179517)
--- branches/safari-600.5-branch/LayoutTests/platform/mac/accessibility/aria-expanded-notifications-expected.txt 2015-02-03 00:57:30 UTC (rev 179516)
+++ branches/safari-600.5-branch/LayoutTests/platform/mac/accessibility/aria-expanded-notifications-expected.txt 2015-02-03 00:57:35 UTC (rev 179517)
@@ -9,6 +9,7 @@
PASS successfullyParsed is true
TEST COMPLETE
+Notification: AXLoadComplete
Notification: AXRowCountChanged
Notification: AXRowCollapsed
Notification: AXRowCountChanged
Modified: branches/safari-600.5-branch/LayoutTests/platform/mac/accessibility/aria-expanded-notifications.html (179516 => 179517)
--- branches/safari-600.5-branch/LayoutTests/platform/mac/accessibility/aria-expanded-notifications.html 2015-02-03 00:57:30 UTC (rev 179516)
+++ branches/safari-600.5-branch/LayoutTests/platform/mac/accessibility/aria-expanded-notifications.html 2015-02-03 00:57:35 UTC (rev 179517)
@@ -32,7 +32,7 @@
function notifyCallback(element, notification) {
notifyName = notification;
document.getElementById("notifications").innerHTML += "Notification: " + notifyName + "<br>";
- if (notifyCount == 3) {
+ if (notifyCount == 4) {
accessibilityController.removeNotificationListener();
window.testRunner.notifyDone();
}
Modified: branches/safari-600.5-branch/Source/WebCore/ChangeLog (179516 => 179517)
--- branches/safari-600.5-branch/Source/WebCore/ChangeLog 2015-02-03 00:57:30 UTC (rev 179516)
+++ branches/safari-600.5-branch/Source/WebCore/ChangeLog 2015-02-03 00:57:35 UTC (rev 179517)
@@ -1,5 +1,35 @@
2015-01-20 Babak Shafiei <bshaf...@apple.com>
+ Merge r174741.
+
+ 2014-10-13 Chris Fleizach <cfleiz...@apple.com>
+
+ AX: Going back is broken for VoiceOver
+ https://bugs.webkit.org/show_bug.cgi?id=137382
+
+ Reviewed by Darin Adler.
+
+ There were two issues preventing VoiceOver from navigating when using page history to go back/forward.
+ 1) Existing AXLoadComplete does not get fired when you just move through page history.
+ There were existing frameLoad notifications used by GTK. I think we should use those which seem more reliable.
+ 2) The AccessibilityScrollView cached its children, but on some history page loads, that cache was never cleared out.
+ Rather than trying to find those places to clear out the cache, it's easier to just add the elements to the children
+ array everytime it's asked for. Since there's only ever 3 elements (web area + 2 scroll bars) this should not be a performance hit.
+
+ Tests are not possible since they require monitoring notifications across multiple page loads.
+
+ * accessibility/AXObjectCache.h:
+ * accessibility/AccessibilityScrollView.cpp:
+ (WebCore::AccessibilityScrollView::updateChildrenIfNecessary):
+ * accessibility/ios/AXObjectCacheIOS.mm:
+ (WebCore::AXObjectCache::frameLoadingEventPlatformNotification):
+ * accessibility/mac/AXObjectCacheMac.mm:
+ (WebCore::AXObjectCache::frameLoadingEventPlatformNotification):
+ * dom/Document.cpp:
+ (WebCore::Document::implicitClose):
+
+2015-01-20 Babak Shafiei <bshaf...@apple.com>
+
Merge r174712.
2014-10-14 Dan Bernstein <m...@apple.com>
Modified: branches/safari-600.5-branch/Source/WebCore/accessibility/AXObjectCache.h (179516 => 179517)
--- branches/safari-600.5-branch/Source/WebCore/accessibility/AXObjectCache.h 2015-02-03 00:57:30 UTC (rev 179516)
+++ branches/safari-600.5-branch/Source/WebCore/accessibility/AXObjectCache.h 2015-02-03 00:57:35 UTC (rev 179517)
@@ -165,6 +165,7 @@
AXFocusedUIElementChanged,
AXLayoutComplete,
AXLoadComplete,
+ AXNewDocumentLoadComplete,
AXSelectedChildrenChanged,
AXSelectedTextChanged,
AXValueChanged,
Modified: branches/safari-600.5-branch/Source/WebCore/accessibility/AccessibilityScrollView.cpp (179516 => 179517)
--- branches/safari-600.5-branch/Source/WebCore/accessibility/AccessibilityScrollView.cpp 2015-02-03 00:57:30 UTC (rev 179516)
+++ branches/safari-600.5-branch/Source/WebCore/accessibility/AccessibilityScrollView.cpp 2015-02-03 00:57:35 UTC (rev 179517)
@@ -106,13 +106,11 @@
void AccessibilityScrollView::updateChildrenIfNecessary()
{
- if (m_childrenDirty)
- clearChildren();
-
- if (!m_haveChildren)
- addChildren();
-
- updateScrollbars();
+ // Always update our children when asked for them so that we don't inadvertently cache them after
+ // a new web area has been created for this scroll view (like when moving back and forth through history).
+ // Since a ScrollViews children will always be relatively small and limited this should not be a performance problem.
+ clearChildren();
+ addChildren();
}
void AccessibilityScrollView::updateScrollbars()
Modified: branches/safari-600.5-branch/Source/WebCore/accessibility/ios/AXObjectCacheIOS.mm (179516 => 179517)
--- branches/safari-600.5-branch/Source/WebCore/accessibility/ios/AXObjectCacheIOS.mm 2015-02-03 00:57:30 UTC (rev 179516)
+++ branches/safari-600.5-branch/Source/WebCore/accessibility/ios/AXObjectCacheIOS.mm 2015-02-03 00:57:35 UTC (rev 179517)
@@ -99,8 +99,13 @@
{
}
-void AXObjectCache::frameLoadingEventPlatformNotification(AccessibilityObject*, AXLoadingEvent)
+void AXObjectCache::frameLoadingEventPlatformNotification(AccessibilityObject* axFrameObject, AXLoadingEvent loadingEvent)
{
+ if (!axFrameObject)
+ return;
+
+ if (loadingEvent == AXLoadingFinished && axFrameObject->document() == axFrameObject->topDocument())
+ postPlatformNotification(axFrameObject, AXLoadComplete);
}
void AXObjectCache::platformHandleFocusedUIElementChanged(Node*, Node* newNode)
Modified: branches/safari-600.5-branch/Source/WebCore/accessibility/mac/AXObjectCacheMac.mm (179516 => 179517)
--- branches/safari-600.5-branch/Source/WebCore/accessibility/mac/AXObjectCacheMac.mm 2015-02-03 00:57:30 UTC (rev 179516)
+++ branches/safari-600.5-branch/Source/WebCore/accessibility/mac/AXObjectCacheMac.mm 2015-02-03 00:57:35 UTC (rev 179517)
@@ -160,8 +160,13 @@
{
}
-void AXObjectCache::frameLoadingEventPlatformNotification(AccessibilityObject*, AXLoadingEvent)
+void AXObjectCache::frameLoadingEventPlatformNotification(AccessibilityObject* axFrameObject, AXLoadingEvent loadingEvent)
{
+ if (!axFrameObject)
+ return;
+
+ if (loadingEvent == AXLoadingFinished && axFrameObject->document() == axFrameObject->topDocument())
+ postPlatformNotification(axFrameObject, AXLoadComplete);
}
void AXObjectCache::platformHandleFocusedUIElementChanged(Node*, Node*)
Modified: branches/safari-600.5-branch/Source/WebCore/dom/Document.cpp (179516 => 179517)
--- branches/safari-600.5-branch/Source/WebCore/dom/Document.cpp 2015-02-03 00:57:30 UTC (rev 179516)
+++ branches/safari-600.5-branch/Source/WebCore/dom/Document.cpp 2015-02-03 00:57:35 UTC (rev 179517)
@@ -2461,10 +2461,14 @@
// The AX cache may have been cleared at this point, but we need to make sure it contains an
// AX object to send the notification to. getOrCreate will make sure that an valid AX object
// exists in the cache (we ignore the return value because we don't need it here). This is
- // only safe to call when a layout is not in progress, so it can not be used in postNotification.
+ // only safe to call when a layout is not in progress, so it can not be used in postNotification.
+ //
+ // This notification is now called AXNewDocumentLoadComplete because there are other handlers that will
+ // catch new AND page history loads, and that uses AXLoadComplete
+
axObjectCache()->getOrCreate(renderView());
if (this == &topDocument())
- axObjectCache()->postNotification(renderView(), AXObjectCache::AXLoadComplete);
+ axObjectCache()->postNotification(renderView(), AXObjectCache::AXNewDocumentLoadComplete);
else {
// AXLoadComplete can only be posted on the top document, so if it's a document
// in an iframe that just finished loading, post AXLayoutComplete instead.