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

Unified Diff: ui/accessibility/platform/ax_platform_node_win.cc

Issue 1987213002: Clean up code and logic related to platform accessibility node destruction. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 7 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 | « ui/accessibility/platform/ax_platform_node_win.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/accessibility/platform/ax_platform_node_win.cc
diff --git a/ui/accessibility/platform/ax_platform_node_win.cc b/ui/accessibility/platform/ax_platform_node_win.cc
index 6cf37f457b37a02639a74518787f5001a1852464..4801322bb70551c4890dc53668fe111cc1670c2d 100644
--- a/ui/accessibility/platform/ax_platform_node_win.cc
+++ b/ui/accessibility/platform/ax_platform_node_win.cc
@@ -138,23 +138,25 @@ AXPlatformNodeWin::AXPlatformNodeWin() {
}
AXPlatformNodeWin::~AXPlatformNodeWin() {
- CHECK(!delegate_);
}
//
-// AXPlatformNode implementation.
+// AXPlatformNodeBase implementation.
//
+void AXPlatformNodeWin::Dispose() {
+ Release();
+}
+
void AXPlatformNodeWin::Destroy() {
- AXPlatformNode::Destroy();
- // Do not call base class AXPlatformNodeBase::Destroy method because it
- // would delete this object. Call base's base class AXPlatformNode::Destroy
- // instead to remove the unique ID from the map like base class does.
- delegate_ = nullptr;
RemoveAlertTarget();
- Release();
+ AXPlatformNodeBase::Destroy();
}
+//
+// AXPlatformNode implementation.
+//
+
gfx::NativeViewAccessible AXPlatformNodeWin::GetNativeViewAccessible() {
return this;
}
« no previous file with comments | « ui/accessibility/platform/ax_platform_node_win.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698