Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(746)

Unified Diff: Source/core/dom/Document.cpp

Issue 495763005: Switch to using accessibilityEnabled and inlineTextBoxAccessibilityEnabled from settings (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Make WebAXObject methods noops Created 6 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: Source/core/dom/Document.cpp
diff --git a/Source/core/dom/Document.cpp b/Source/core/dom/Document.cpp
index ad901ee9f0a31e05ae7cdc8c6c3551b5b8e5ab1d..42cc5b687803fefd5c522395e64c57d105bd755f 100644
--- a/Source/core/dom/Document.cpp
+++ b/Source/core/dom/Document.cpp
@@ -2262,9 +2262,6 @@ void Document::clearAXObjectCache()
AXObjectCache* Document::existingAXObjectCache() const
{
- if (!AXObjectCache::accessibilityEnabled())
- return 0;
-
// If the renderer is gone then we are in the process of destruction.
// This method will be called before m_frame = 0.
if (!topDocument().renderView())
@@ -2275,7 +2272,7 @@ AXObjectCache* Document::existingAXObjectCache() const
AXObjectCache* Document::axObjectCache() const
{
- if (!AXObjectCache::accessibilityEnabled())
+ if (!settings() || !settings()->accessibilityEnabled())
abarth-chromium 2014/08/23 05:59:11 Please don't call settings() twice. It's not free
aboxhall 2014/08/27 15:26:33 Done.
return 0;
// The only document that actually has a AXObjectCache is the top-level
@@ -2577,7 +2574,7 @@ void Document::implicitClose()
m_loadEventProgress = LoadEventCompleted;
- if (frame() && renderView() && AXObjectCache::accessibilityEnabled()) {
+ if (frame() && renderView() && settings() && settings()->accessibilityEnabled()) {
// 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

Powered by Google App Engine
This is Rietveld 408576698