On Fri, 02 Dec 2005 14:42:36 +0100
Vincent Snijders <[EMAIL PROTECTED]> wrote:

>[...]
> On windows it is not working yet. I cannot figure out how to make the 
> LCL and windows itself work together in managing the capturing.
> 
> How are they supposed to work together?
> 
> Let me explain a bit more of my dilemma.
> 
> Windows sets the Capture in its default handling of wm_lbuttondown and 
> releases it wm_lbuttonup.
> 
> The LCL is doing the same, if a Control has the csMouseCapture Control 
> Style, which most controls actually have, because it is set in 
> TControl's default.
> 
> Now, if I let the LCL handle the messages first, the capture is lost 
> when windows handles wm_lbuttonup, which results in some events not 
> firing (e.g. TButton Click, which is triggered by a WM_COMMAND, 
> BN_CLICKED combination).

So winapi needs to capture itself?

 
> If I let windows handle the message first, the LCL doesn't pass the 
> message to the TCustomControl in IsControlMouseMsg, because the LCL asks 
> the interface if any control as the capture and it turns out the 
> (wincontrol) parent of the TCustomControl has the capture.

Somehow the CaptureControl variable needs to be set when the winapi captures
the mouse.
Does the win32 intf know, when winapi has captured? Then maybe it could
adjust the variable.


Mattias

_________________________________________________________________
     To unsubscribe: mail [EMAIL PROTECTED] with
                "unsubscribe" as the Subject
   archives at http://www.lazarus.freepascal.org/mailarchives

Reply via email to