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

Unified Diff: third_party/WebKit/Source/modules/accessibility/AXObjectCacheImpl.cpp

Issue 2939933002: Only call TextChanged on existing AXObjects (Closed)
Patch Set: Created 3 years, 6 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
« no previous file with comments | « third_party/WebKit/Source/core/dom/Text.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/modules/accessibility/AXObjectCacheImpl.cpp
diff --git a/third_party/WebKit/Source/modules/accessibility/AXObjectCacheImpl.cpp b/third_party/WebKit/Source/modules/accessibility/AXObjectCacheImpl.cpp
index 970a804027be2be959290fd30004dc241daeec25..66f7fab3e425f36da16b2d2d11d5a8927627e5dc 100644
--- a/third_party/WebKit/Source/modules/accessibility/AXObjectCacheImpl.cpp
+++ b/third_party/WebKit/Source/modules/accessibility/AXObjectCacheImpl.cpp
@@ -585,11 +585,17 @@ void AXObjectCacheImpl::SelectionChanged(Node* node) {
}
void AXObjectCacheImpl::TextChanged(Node* node) {
- TextChanged(GetOrCreate(node));
+ AXObjectImpl* axObject = Get(node);
+ if (!axObject)
dmazzoni 2017/06/14 18:38:14 I think you could remove this null-check since Tex
aboxhall 2017/06/14 18:46:05 Great, done.
+ return;
+ TextChanged(axObject);
}
void AXObjectCacheImpl::TextChanged(LayoutObject* layout_object) {
- TextChanged(GetOrCreate(layout_object));
+ AXObjectImpl* axObject = Get(layout_object);
+ if (!axObject)
dmazzoni 2017/06/14 18:38:14 Same
aboxhall 2017/06/14 18:46:05 Done.
+ return;
+ TextChanged(axObject);
}
void AXObjectCacheImpl::TextChanged(AXObjectImpl* obj) {
« no previous file with comments | « third_party/WebKit/Source/core/dom/Text.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698