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

Side by Side Diff: ui/views/win/hwnd_message_handler.cc

Issue 1903223005: Fix for 593676 - Minimizes/eliminates momentary flash of Windows frame (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Revert previous change. Modified code actually causing the issue Created 4 years, 8 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 unified diff | Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "ui/views/win/hwnd_message_handler.h" 5 #include "ui/views/win/hwnd_message_handler.h"
6 6
7 #include <dwmapi.h> 7 #include <dwmapi.h>
8 #include <oleacc.h> 8 #include <oleacc.h>
9 #include <shellapi.h> 9 #include <shellapi.h>
10 #include <tchar.h> 10 #include <tchar.h>
(...skipping 2308 matching lines...) Expand 10 before | Expand all | Expand 10 after
2319 2319
2320 SetMsgHandled(FALSE); 2320 SetMsgHandled(FALSE);
2321 } 2321 }
2322 2322
2323 void HWNDMessageHandler::OnWindowPosChanged(WINDOWPOS* window_pos) { 2323 void HWNDMessageHandler::OnWindowPosChanged(WINDOWPOS* window_pos) {
2324 if (DidClientAreaSizeChange(window_pos)) 2324 if (DidClientAreaSizeChange(window_pos))
2325 ClientAreaSizeChanged(); 2325 ClientAreaSizeChanged();
2326 if (!delegate_->HasFrame() && window_pos->flags & SWP_FRAMECHANGED && 2326 if (!delegate_->HasFrame() && window_pos->flags & SWP_FRAMECHANGED &&
2327 ui::win::IsAeroGlassEnabled() && 2327 ui::win::IsAeroGlassEnabled() &&
2328 (window_ex_style() & WS_EX_COMPOSITED) == 0) { 2328 (window_ex_style() & WS_EX_COMPOSITED) == 0) {
2329 MARGINS m = {10, 10, 10, 10}; 2329 MARGINS m = {1, 1, 1, 1};
kylix_rd 2016/04/25 21:42:13 I've uploaded this change for discussion purposes.
2330 DwmExtendFrameIntoClientArea(hwnd(), &m); 2330 DwmExtendFrameIntoClientArea(hwnd(), &m);
2331 } 2331 }
2332 if (window_pos->flags & SWP_SHOWWINDOW) { 2332 if (window_pos->flags & SWP_SHOWWINDOW) {
2333 delegate_->HandleVisibilityChanged(true); 2333 delegate_->HandleVisibilityChanged(true);
2334 if (direct_manipulation_helper_) 2334 if (direct_manipulation_helper_)
2335 direct_manipulation_helper_->Activate(hwnd()); 2335 direct_manipulation_helper_->Activate(hwnd());
2336 } else if (window_pos->flags & SWP_HIDEWINDOW) { 2336 } else if (window_pos->flags & SWP_HIDEWINDOW) {
2337 delegate_->HandleVisibilityChanged(false); 2337 delegate_->HandleVisibilityChanged(false);
2338 if (direct_manipulation_helper_) 2338 if (direct_manipulation_helper_)
2339 direct_manipulation_helper_->Deactivate(hwnd()); 2339 direct_manipulation_helper_->Deactivate(hwnd());
(...skipping 339 matching lines...) Expand 10 before | Expand all | Expand 10 after
2679 delegate_->HandleClientSizeChanged(GetClientAreaBounds().size()); 2679 delegate_->HandleClientSizeChanged(GetClientAreaBounds().size());
2680 ResetWindowRegion(false, true); 2680 ResetWindowRegion(false, true);
2681 } 2681 }
2682 2682
2683 if (direct_manipulation_helper_) 2683 if (direct_manipulation_helper_)
2684 direct_manipulation_helper_->SetBounds(bounds_in_pixels); 2684 direct_manipulation_helper_->SetBounds(bounds_in_pixels);
2685 } 2685 }
2686 2686
2687 2687
2688 } // namespace views 2688 } // namespace views
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698