1. [Win] Knowing when mouse leaves window?

I've got a problem with a program in which I have a non-full screen window.
I need to know when the mouse leaves my window and goes onto the desktop.
Specifically, I need to know when the mouse event is LeftUp on the desktop.

Can anyone help me?

Thanks,

Judith Evans

new topic     » topic index » view message » categorize

2. Re: [Win] Knowing when mouse leaves window?

> From: Judith Evans
>
> I've got a problem with a program in which I have a non-full
> screen window.
> I need to know when the mouse leaves my window and goes onto
> the desktop.
> Specifically, I need to know when the mouse event is LeftUp
> on the desktop.

Use captureMouse.  From win32lib.htm:

captureMouse( window )
Send all mouse events to window.
Category: Mouse
To release the mouse, use releaseMouse.

Example:


          -- grab the mouse for TheWindow
          captureMouse( TheWindow )


releaseMouse()
Return control of the mouse to Windows.
Category: Mouse
This is called after captureMouse to put control of the mouse back to
normal.

Example:


          -- release the mouse.
          releaseMouse()


Matt Lewis

new topic     » goto parent     » topic index » view message » categorize

3. Re: [Win] Knowing when mouse leaves window?

Thanks, Matt

I had tried captureMouse once before without any luck but this time it does
the trick.

Judith

On Tue, 17 Oct 2000 15:18:43 -0700, Matthew Lewis <MatthewL at KAPCOUSA.COM>
wrote:

>> From: Judith Evans
>>
>> I've got a problem with a program in which I have a non-full
>> screen window.
>> I need to know when the mouse leaves my window and goes onto
>> the desktop.
>> Specifically, I need to know when the mouse event is LeftUp
>> on the desktop.
>
>Use captureMouse.  From win32lib.htm:
>
>captureMouse( window )
>Send all mouse events to window.
>Category: Mouse
>To release the mouse, use releaseMouse.
>

>
>Matt Lewis

new topic     » goto parent     » topic index » view message » categorize

Search



Quick Links

User menu

Not signed in.

Misc Menu