[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Gnustep-cvs] r31213 - in /libs/gui/trunk: ChangeLog Source/NSMenuVi
From: |
Doug Simons |
Subject: |
Re: [Gnustep-cvs] r31213 - in /libs/gui/trunk: ChangeLog Source/NSMenuView.m Source/NSPopUpButtonCell.m |
Date: |
Wed, 27 Oct 2010 16:21:13 -0600 |
Thanks for the suggestion, Kai. But the problem is that we'd like to not change
existing GNUstep code in awkward ways. The code uses the standard
nextEventMatchingMask:... method to get the next event, which inevitably calls
some Windows function that allows the callbacks to come in.
Fortunately, after a lot of head scratching we've found a good solution, which
I'll post in a moment in response to my earlier message.
Doug
On Oct 27, 2010, at 8:43 AM, SPUeNTRUP - Kai Henningsen wrote:
> Hallo Doug,
>
> Am Tue, 26 Oct 2010 21:49:28 -0600
> schrieb Doug Simons <address@hidden>:
>
>> 2. Figure out a more general solution for blocking callbacks from Windows
>> while getting events. This would be ideal,
>
> Surely those callbacks only happen when we call LRESULT DispatchMessage(const
> MSG *lpmsg); ?
>
> More precisely, the typical message loop looks like this:
>
> // Start the message loop.
> while( (bRet = GetMessage( &msg, NULL, 0, 0 )) != 0)
> {
> if (bRet == -1)
> {
> // handle the error and possibly exit
> }
> else
> {
> TranslateMessage(&msg);
> DispatchMessage(&msg); <<< callbacks happen here
> }
> }
>
> It's not as if windows does callbacks here without being explicitly
> asked to. Presumably, you could just as well queue messages up and
> dispatch them later, if that is more convenient. Or ignore them
> altogether.
>
> For Windows API docs, see around here:
>
> http://msdn.microsoft.com/en-us/library/ms644928%28v=VS.85%29.aspx#creating_loop
>
> Mit freundlichen Grüßen aus Münster /
> with kind regards - Kai Henningsen
>
> --
> SPUeNTRUP Software
> An der Kleimannbrücke 52
> D-48157 Münster, Germany
>
> Reg: Münster Nr.29047
>
> Fon: +49 700 CALL CATS (=22552287)
> Fon: +49 251 322 311 0
> Fax: +49 251 322 311 99
>
> Web: http://www.cats.ms
> Mail: address@hidden
>
> _______________________________________________
> Gnustep-dev mailing list
> address@hidden
> http://lists.gnu.org/mailman/listinfo/gnustep-dev
>