Closed Bug 641705 Opened 9 years ago Closed 9 years ago

Deferred message processing drops gecko notification events

Categories

(Core :: IPC, defect)

x86
Windows 7
defect
Not set

Tracking

()

RESOLVED FIXED
mozilla5

People

(Reporter: jimm, Assigned: jimm)

Details

Attachments

(1 file)

nsAppShell on Windows uses a registered message to trigger gecko event process. 

In WindowsMessageLoop we hook the message window into deferred processing,

http://mxr.mozilla.org/mozilla-central/source/ipc/glue/WindowsMessageLoop.cpp#381

but we don't handle the kAppShellEventId message in our deferred message handler. If these events get dropped all sort of weird things can happen, including the dreaded "the ui only updates when I move the mouse" bug.

We need to make sure and defer this event properly.
Attached patch patchSplinter Review
Attachment #519424 - Flags: review?(benjamin)
(I'll ditch that makefile whitespace edit in the final.)
Comment on attachment 519424 [details] [diff] [review]
patch

>     default: {
>+      if (uMsg && uMsg == sAppShellGeckoMsgId) {

Er, can't you add this to the rest of the DeferredSendMessage block above rather than mess with the default block?
Attachment #519424 - Flags: review?(benjamin) → review+
You could if you were in JS: C++ requires consts ;-)
There's a little bug in this:

if (uMsg && uMsg == sAppShellGeckoMsgId)

That should have been:

if (sAppShellGeckoMsgId && uMsg == sAppShellGeckoMsgId)

since RegisterWindowMessage can fail and return zero. I'll touch this up before I land it.
(In reply to comment #5)
> There's a little bug in this:
> 
> if (uMsg && uMsg == sAppShellGeckoMsgId)
> 
> That should have been:
> 
> if (sAppShellGeckoMsgId && uMsg == sAppShellGeckoMsgId)
> 
> since RegisterWindowMessage can fail and return zero. I'll touch this up before
> I land it.

Actually, it works both ways. I left it alone.

http://hg.mozilla.org/mozilla-central/rev/8442a1f9aaba
Status: NEW → RESOLVED
Closed: 9 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla5
This was fixed on 25-Mar, it is certainly in Aurora, and I'm pretty sure it's in beta (TM is mozilla5).
You need to log in before you can comment on or make changes to this bug.