mouseDown and within

Pat Trendler ptrendler at bigpond.com
Sat Apr 23 08:50:50 EDT 2005


Just another thought, you can use -  if the mouse is "down"
for example as in the following (a bit sloppy scripting but it does work OK)

on mouseMove
  if the mouse is "down" then
    repeat with i = 1 to 4
      if the mouseLoc is within the rect of btn i then
        set the backgroundcolor of btn i to "blue"
      end if
    end repeat
  end if
end mouseMove

Correction to my previous mail I should have said you can get mouseStillDown 
if the handler is in the script of the target btn.

Pat

----- Original Message ----- 
From: "Pat Trendler" <ptrendler at bigpond.com>
To: "How to use Revolution" <use-revolution at lists.runrev.com>
Sent: Saturday, April 23, 2005 1:26 PM
Subject: Re: mouseDown and within


> Tom,
> You can get mouseStillDown if it's in the target btn and also you can 
> always get the mouseloc. A bit of fiddling with these two should get you 
> what you want.
>
> HTH
>
> Pat
>
> ----- Original Message ----- 
> From: "Thomas McGrath III" <3mcgrath at adelphia.net>
> To: "How to use Revolution" <use-revolution at lists.runrev.com>
> Sent: Saturday, April 23, 2005 11:56 AM
> Subject: mouseDown and within
>
>
>> Hello all,
>>
>> I have a few buttons and when the mouse is down over a button the 
>> background turns blue. This is good. Now I want to have the other buttons 
>> turn blue by still holding the mouseDown but moving it over the other 
>> buttons and when it is over them that they will act like a mouseDown has 
>> been sent to them.
>>
>> I have tried mouseDown, mouseStillDown, mouseWithin, mouseEnter etc.
>>
>> No luck,
>>
>> I might be able to do a mouseOver (SC) but prefer the mouseDown if 
>> possible.
>>
>> Does anyone know a way to do this????
>>
>> Thanks in advance....
>>
>> Tom
>>
>>
>> Thomas J. McGrath III
>> SCS
>> 1000 Killarney Dr.
>> Pittsburgh, PA 15234
>> 412-885-8541
>>
>> _______________________________________________
>> use-revolution mailing list
>> use-revolution at lists.runrev.com
>> http://lists.runrev.com/mailman/listinfo/use-revolution
>
> _______________________________________________
> use-revolution mailing list
> use-revolution at lists.runrev.com
> http://lists.runrev.com/mailman/listinfo/use-revolution
> 



More information about the use-livecode mailing list