🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.windows.misc
Article #1067

Re: I want my BUTTON1UP (PMSDK 1.05)

#1067
From: Tim Villanueva
Date: Mon, 14 Nov 1988 20:46
19 lines
1321 bytes
>Here's the problem: it clears this variable when it gets a WM_BUTTON1UP
>message, WHICH IT ONLY GETS IT YOU LET GO OF THE BUTTON **IN ITS WINDOW**.
>If you push button 1, then move out onto the desktop or another window,
>*THEN* let go of button 1, the dragging program doesn't clear its dragging


You should use BUTTONUP and BUTTONDOWN as special case state transitions.
Set your "flags" not ONLY on these messages, but on MOUSEMOVE messages.
You will get a flag with the MOUSEMOVE message that tells you whether either
or both buttons are down.  Depending on the previous state of the button
in question, you can take appropriate action.

Thus, when the mouse is released ouside your window, and then drug back
into your window, you know on the FIRST mousemove that the button is up.

BUTTONUP and BUTTONDOWN simply take care of the special case of when the
user clicks without moving  (to draw a DOT in a paint program maybe).

      Tim V
Technical Details
Message-ID: <8130007@hpccc.HP.COM>
Path: arc1-ca.pugleaf.net!utzoo!attcan!uunet!ncrlnk!ncr-sd!hp-sdd!hplabs!hpl-opus!hpccc!tvillan
References: <11151@cup.portal.com>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!attcan!uunet!ncrlnk!ncr-sd!hp-sdd!hplabs!hpl-opus!hpccc!tvillan
From: tvillan@hpccc.HP.COM (Tim Villanueva)
Newsgroups: comp.windows.misc
Subject: Re: I want my BUTTON1UP (PMSDK 1.05)
Message-ID: <8130007@hpccc.HP.COM>
Date: 14 Nov 88 20:46:06 GMT
References: <11151@cup.portal.com>
Organization: Personal Software Division
Lines: 19