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

Issue 22353018: Fix aura flickering when not using DWM. (Closed)

Created:
7 years, 4 months ago by zturner
Modified:
7 years, 4 months ago
CC:
chromium-reviews, tfarina, ben+watch_chromium.org, msw
Visibility:
Public.

Description

Fix aura flickering when not using DWM. By directly invoking DefWindowProc outside of the standard WindowProc / message pump flow, the default implementation of WM_NCACTIVATE was causing one frame to render using the standard Windows application look-and-feel. The fix employed here is to use SendMessage, for 2 reasons: 1) It correctly follows Windows' model of 1 message / 1 action 2) It sends the WM_NCACTIVATE through our subclassed window. I'm TBRing sky@ and beng@ since this is a really Windowsy change, but they do not return for a few weeks. Also TBRing ananta@ since he wrote the original implementation of this function, but he's also out until Monday the 12th. BUG=257183, 178600 TBR=sky,beng,ananta Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=216571

Patch Set 1 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+3 lines, -8 lines) Patch
M ui/views/widget/desktop_aura/desktop_root_window_host_win.cc View 1 chunk +3 lines, -8 lines 0 comments Download

Messages

Total messages: 9 (0 generated)
zturner
7 years, 4 months ago (2013-08-07 23:40:04 UTC) #1
sadrul
lgtm
7 years, 4 months ago (2013-08-08 07:24:57 UTC) #2
sadrul
Didn't mean to lgtm. Perhaps +scottmg@ can do a proper review.
7 years, 4 months ago (2013-08-08 07:25:48 UTC) #3
scottmg
Yeah, no idea why we were directly DefWindowProc'ing. lgtm.
7 years, 4 months ago (2013-08-08 14:44:52 UTC) #4
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/zturner@chromium.org/22353018/1
7 years, 4 months ago (2013-08-08 20:29:42 UTC) #5
commit-bot: I haz the power
Change committed as 216571
7 years, 4 months ago (2013-08-09 04:18:33 UTC) #6
ananta
On 2013/08/09 04:18:33, I haz the power (commit-bot) wrote: > Change committed as 216571 Please ...
7 years, 4 months ago (2013-08-09 05:07:29 UTC) #7
scottmg
On 2013/08/09 05:07:29, ananta wrote: > On 2013/08/09 04:18:33, I haz the power (commit-bot) wrote: ...
7 years, 4 months ago (2013-08-09 05:23:21 UTC) #8
zturner
7 years, 4 months ago (2013-08-09 16:58:43 UTC) #9
Message was sent while issue was closed.
On 2013/08/09 05:23:21, scottmg wrote:
> On 2013/08/09 05:07:29, ananta wrote:
> > On 2013/08/09 04:18:33, I haz the power (commit-bot) wrote:
> > > Change committed as 216571
> > 
> > Please check whether this bug
> > https://code.google.com/p/chromium/issues/detail?id=229599 does not recur
with
> > this change.
> > 
> > Thanks
> > Ananta
> 
> Yeah, we made sure the frame still draws as activated when the popup takes
> focus. Shrikant was a bit concerned that SendMessage rather than DefWindowProc
> might cause some strange problems, but we didn't notice any yet at least.

In addition to what scott said, I think it's also worth mentioning that if we do
detect some other strange issues as a result of this change later down the line,
the fix is probably not to revert this change, but to fix them in a different
way.  I think we were invoking undefined behavior by calling DefWindowProc
directly, because it violates the assumption that a single call to WindowProc
handles exactly 1 message: the same one that WindowProc was called with.  We
were handling 2 messages this way, and 1 of them was different than the message
WindowProc was originally invoked with.

Powered by Google App Engine
This is Rietveld 408576698