From 4a4fcb15e4f3d69517ef93694eda0800e8052900 Mon Sep 17 00:00:00 2001 From: "glen@chromium.org" Date: Wed, 3 Jun 2009 18:22:41 +0000 Subject: Fix for crash when changing frame on non-DWM systems. BUG=13075 TEST=Reset the theme on XP and verify that it doesn't crash. Review URL: http://codereview.chromium.org/118171 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@17503 0039d316-1c4b-4281-b951-d872f2087c98 --- views/window/window_win.cc | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'views') diff --git a/views/window/window_win.cc b/views/window/window_win.cc index 3759851..6b9f5d8 100644 --- a/views/window/window_win.cc +++ b/views/window/window_win.cc @@ -191,6 +191,13 @@ static BOOL CALLBACK SendDwmCompositionChanged(HWND window, LPARAM param) { } // namespace void WindowWin::FrameTypeChanged() { + // If we're not on Aero Glass, we don't care doing any of the DWM stuff. Just + // tell the NCV to update and leave it there. + if (!win_util::ShouldUseVistaFrame()) { + non_client_view_->UpdateFrame(); + return; + } + // The window may try to paint in SetUseNativeFrame, and as a result it can // get into a state where it is very unhappy with itself - rendering black // behind the entire client area. This is because for some reason the -- cgit v1.1