messages to buttons when the mouse is already down

Terry Judd tsj at unimelb.edu.au
Mon Jan 21 18:06:01 EST 2002


>I would like to track the movement of the mouse through an array of 
>buttons by hilighting each button that the mouse (button already 
>down) passes over. However, the mouseEnter, mouseMove, mouseWithin 
>messages are only sent to the first button because that button 
>receives the mouseDown event and is the target. Similarly the 
>mouseControl function (yes, it took me a couple of tries to notice 
>that it was a function and not a message!) only returns the target.
>
>How can I get the other buttons to hilight without requiring the 
>user to click each individually?

How about using an idle handler and checking whether the cursor is 
within the rect of the individual buttons - or better still convert 
the mouseloc to an integer reflecting a button position in the array 
- and then set the hilite of the target button (and turn off the 
hilite of any previous target).

Terry...

>--
>Michael J. Lew
>
>Senior Lecturer
>Department of Pharmacology
>The University of Melbourne
>Parkville 3010
>Victoria
>Australia
>
>Phone +613 8344 8304
>
>**
>New email address: michaell at unimelb.edu.au
>**
>_______________________________________________
>use-revolution mailing list
>use-revolution at lists.runrev.com
>http://lists.runrev.com/mailman/listinfo/use-revolution


-- 
___________________________________________________________________________
Dr Terry Judd

Lecturer in Instructional Design / Multimedia Developer
Biomedical Multimedia Unit
Faculty of Medicine, Dentistry & Health Sciences
The University of Melbourne
Email: t.judd at bmu.unimelb.edu.au
Phone: 03 9344 0187
Fax: 03 9344 4998
___________________________________________________________________________



More information about the use-livecode mailing list