diff options
author | ben@chromium.org <ben@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-05-06 23:23:11 +0000 |
---|---|---|
committer | ben@chromium.org <ben@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-05-06 23:23:11 +0000 |
commit | 50ddd8b885c03fe4fba19130918939026ae6ef24 (patch) | |
tree | 4df5857465cbded5c559c917320d2ee09f13eb97 /chrome/views/widget/widget_win.cc | |
parent | efb5ccb4aa5aa111a1e894f8ad22cf6a8f053aba (diff) | |
download | chromium_src-50ddd8b885c03fe4fba19130918939026ae6ef24.zip chromium_src-50ddd8b885c03fe4fba19130918939026ae6ef24.tar.gz chromium_src-50ddd8b885c03fe4fba19130918939026ae6ef24.tar.bz2 |
Reverting 15468.
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@15470 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/views/widget/widget_win.cc')
-rw-r--r-- | chrome/views/widget/widget_win.cc | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/chrome/views/widget/widget_win.cc b/chrome/views/widget/widget_win.cc index 5ee065a..0bb3e78 100644 --- a/chrome/views/widget/widget_win.cc +++ b/chrome/views/widget/widget_win.cc @@ -9,12 +9,14 @@ #include "base/string_util.h" #include "base/win_util.h" #include "chrome/app/chrome_dll_resource.h" +#include "chrome/common/notification_service.h" #include "chrome/common/win_util.h" #include "chrome/views/accessibility/view_accessibility.h" #include "chrome/views/controls/native_control_win.h" #include "chrome/views/fill_layout.h" #include "chrome/views/focus/focus_util_win.h" #include "chrome/views/widget/aero_tooltip_manager.h" +#include "chrome/views/widget/hwnd_notification_source.h" #include "chrome/views/widget/root_view.h" #include "chrome/views/window/window_win.h" @@ -465,6 +467,12 @@ void WidgetWin::OnCaptureChanged(HWND hwnd) { } void WidgetWin::OnClose() { + // WARNING: this method is NOT called for all WidgetWins. If you need to do + // cleanup code before WidgetWin is destroyed, put it in OnDestroy. + NotificationService::current()->Notify( + NotificationType::WINDOW_CLOSED, Source<HWND>(hwnd_), + NotificationService::NoDetails()); + Close(); } |