Index: Source/WebCore/page/FocusController.cpp |
=================================================================== |
--- Source/WebCore/page/FocusController.cpp (revision 146890) |
+++ Source/WebCore/page/FocusController.cpp (working copy) |
@@ -253,8 +253,8 @@ |
// If focus is being set initially, accessibility needs to be informed that system focus has moved |
// into the web area again, even if focus did not change within WebCore. PostNotification is called instead |
// of handleFocusedUIElementChanged, because this will send the notification even if the element is the same. |
- if (AXObjectCache* cache = focusedOrMainFrame()->document()->existingAXObjectCache()) |
- cache->postNotification(focusedOrMainFrame()->document(), AXObjectCache::AXFocusedUIElementChanged, true); |
+ if (AXObjectCache::accessibilityEnabled()) |
+ focusedOrMainFrame()->document()->axObjectCache()->postNotification(focusedOrMainFrame()->document(), AXObjectCache::AXFocusedUIElementChanged, true); |
return didAdvanceFocus; |
} |