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

Unified Diff: ui/views/window/dialog_delegate.cc

Issue 11953066: Reland 179231 (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 11 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
« ash/launcher/launcher.cc ('K') | « ui/views/window/dialog_delegate.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/views/window/dialog_delegate.cc
diff --git a/ui/views/window/dialog_delegate.cc b/ui/views/window/dialog_delegate.cc
index 439f5ccc56b664d058ed6098a06b3f1bc0ba0671..b4bfdeb680504e9221cadd7a6707b2afd436429d 100644
--- a/ui/views/window/dialog_delegate.cc
+++ b/ui/views/window/dialog_delegate.cc
@@ -126,11 +126,17 @@ ui::AccessibilityTypes::Role DialogDelegate::GetAccessibleWindowRole() const {
// DialogDelegateView:
DialogDelegateView::DialogDelegateView() {
+ // A WidgetDelegate should be deleted on DeleteDelegate.
+ set_owned_by_client();
}
DialogDelegateView::~DialogDelegateView() {
}
+void DialogDelegateView::DeleteDelegate() {
+ delete this;
+}
+
Widget* DialogDelegateView::GetWidget() {
return View::GetWidget();
}
« ash/launcher/launcher.cc ('K') | « ui/views/window/dialog_delegate.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698