DescriptionGet rid of the 1-pixel client inset hack.
This patch attempts to fix various graphical glitches and corruption
once and for all. The root of all these issues is the 1-pixel bottom
client inset hack, so this patch aims to replace that hack with a
(hopefully) less onerous hack.
Prior to this patch, there was a comment indicating that before
changing the frame type we must hide the window (and then show the window
after the frame type is changed) or else the client area will paint black.
However, no code was present to actually do this. The original comment also
indicated that this was not necessary for chrome theme changes, but rather
only WM_DWMCOMPOSITIONCHANGED messages, but testing showed that this is
not the case, and it is in fact required for both cases.
Additionally, after changing the frame type, it is required to call
SetWindowPos() with SWP_FRAMECHANGED in order to notify windows of the
change.
BUG=312535, 311405
TEST=
Classic -> Aero Test (Win7 only)
0. Shutdown Chrome
1. Set a Windows 7 Basic Theme
2. Start Chrome
3. Change to Windows 7 Aero Theme
4. Observe correct rendering of browser frame
Aero -> Classic Test (Win7 only)
0. Shutdown Chrome
1. Set a Windows 7 Aero Theme
2. Start Chrome
3. Change to Windows 7 Basic Theme
4. Observe correct rendering of browser frame
Chrome Theme Test (Win7 w/ Aero Theme, Win8, Win8.1)
1. Hotdog -> Settings -> Reset to Default Theme
2. Close Chrome
3. Start Chrome
4. Install Brushed Theme
https://chrome.google.com/webstore/detail/brushed/bfjgbcjfpbbfepcccpaffkjofcmglifg?hl=en
5. Close Chrome
6. Start Chrome
7. Hotdog -> Settings -> Reset to Default Theme
8. Observe correct rendering of browser frame
Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=234386
Patch Set 1 #Patch Set 2 : Add a call to UpdateWindow after hide/reshow. #Patch Set 3 : Remove comment about issue still persisting, since it appears fixed. #Patch Set 4 : Re-add comment about remaining issue. #
Total comments: 1
Patch Set 5 : Fix the black title bar on classic -> glass theme change. #Patch Set 6 : Fix black title bar on classic -> glass theme change. #
Total comments: 1
Patch Set 7 : Rebase to ToT #
Total comments: 4
Messages
Total messages: 19 (0 generated)
|