Ove wrote:
> That is, we'd do:
>
> Service thread:
> 0. Receive Expose
> 1. Invalidate window rectangle
> 2. SendNotifyMessage(wnd,WM_SYNCPAINT,0,0);
> 3. Forget it and move on to doing other stuff
>
> DefWndProc:
> 0. Receive WM_SYNCPAINT
> 1. Check update region
> 2. Send ERASEBKGND and NCPAINT messages as necessary...
>
> Right now, the service thread sends ERASEBKGND and NCPAINT messages
> itself, which is a deadlock condition in multimedia apps. This would solve
> those, too...
>

I'm not sure you should let the service thread do the invalidation. I think
it is better to do it in the DefWndProc while processing WM_SYNCPAINT. You
don't want have more than one thread playing with hrgnUpdate field in the
window structure.

        Stephane Lussier
        Macadamian Technologies

Reply via email to