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

Issue 2753813003: Fix theme change paint issue on linux. (Closed)

Created:
3 years, 9 months ago by ananta
Modified:
3 years, 9 months ago
Reviewers:
sky
CC:
chromium-reviews, tfarina
Target Ref:
refs/pending/branch-heads/3029
Project:
chromium
Visibility:
Public.

Description

Fix theme change paint issue on linux. Merging to M58 We had added a recursion guard in the Widget::OnNativeThemeUpdated() function in this patch https://codereview.chromium.org/2703933002. This was to work around a crash we were seeing on Windows where views would be added/removed while the rootview was propagating the theme changed notification to child views effectively making the iterators invalid. The recursion killer check in Widget::FrameTypeChanged() causes a painting bug on Linux. The callstack thanks to thomasanderson is here. The BrowserView::UserChangedTheme() function also has a recursion killer which is not set to true here, which indicates that this stack is legitimate. Fixes as below: 1. BrowserFrame now overrides the Widget::OnNativeThemeUpdated() function. After calling the base class we call the newly added function NativeThemeUpdated() in the BrowserView which ensures that we don't nuke the views while the iteration is going on in View::PropagateNativeThemeChanged() 2. In the HWNDMessageHandler::SetFullscreen method we update the fullscreen window map after we call PerformDwmTransition(). This internally at times causes a window pos changed to treat the now non fullscreen window as fullscreen leading to a DCHECK. Fixed by moving this code above. I verified that this does not regress the previous theme fix http://crbug.com/681525 on Windows. BUG=700135 TBR=sky NOTRY=true NOPRESUBMIT=true Review-Url: https://codereview.chromium.org/2743793003 Cr-Commit-Position: refs/heads/master@{#456580} (cherry picked from commit 3d0d1cdfad3fd70d8d579dd03004b4e09d01f2f1) Review-Url: https://codereview.chromium.org/2753813003 Cr-Commit-Position: refs/branch-heads/3029@{#214} Cr-Branched-From: 939b32ee5ba05c396eef3fd992822fcca9a2e262-refs/heads/master@{#454471} Committed: https://chromium.googlesource.com/chromium/src/+/9b58fa9d8b8e60498a56101a16987d85d9ffecab

Patch Set 1 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+30 lines, -27 lines) Patch
M chrome/browser/ui/views/frame/browser_frame.h View 1 chunk +1 line, -0 lines 0 comments Download
M chrome/browser/ui/views/frame/browser_frame.cc View 1 chunk +5 lines, -0 lines 0 comments Download
M chrome/browser/ui/views/frame/browser_view.h View 2 chunks +3 lines, -1 line 0 comments Download
M chrome/browser/ui/views/frame/browser_view.cc View 2 chunks +16 lines, -11 lines 0 comments Download
M ui/views/widget/widget.h View 1 chunk +0 lines, -3 lines 0 comments Download
M ui/views/widget/widget.cc View 3 chunks +1 line, -8 lines 0 comments Download
M ui/views/win/hwnd_message_handler.cc View 2 chunks +4 lines, -4 lines 0 comments Download

Messages

Total messages: 13 (8 generated)
ananta
3 years, 9 months ago (2017-03-15 20:06:03 UTC) #3
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2753813003/1
3 years, 9 months ago (2017-03-15 20:08:49 UTC) #5
commit-bot: I haz the power
CLs for remote refs other than refs/heads/master must contain NOTRY=true and NOPRESUBMIT=true in order for ...
3 years, 9 months ago (2017-03-15 20:08:50 UTC) #7
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2753813003/1
3 years, 9 months ago (2017-03-15 20:11:47 UTC) #10
commit-bot: I haz the power
3 years, 9 months ago (2017-03-15 20:25:14 UTC) #13
Message was sent while issue was closed.
Committed patchset #1 (id:1) as
https://chromium.googlesource.com/chromium/src/+/9b58fa9d8b8e60498a56101a1698...

Powered by Google App Engine
This is Rietveld 408576698