> On 5/9/13 12:42 PM, "Richmond" <richmondmathew...@gmail.com> wrote:
> 
>> On 05/09/2013 09:01 PM, Mark Wieder wrote:
>>> Ray Horsley <ray@...> writes:
>>> 
>>>> What am I missing to get drag/drop working consistently?
>>> You might also want to look at
>>> 
>>> 
>>> <http://lessons.runrev.com/s/lessons/m/4071/l/7124-pinning-drag-and-drop-
>>> to-the-mat-a-primer>
>>> 
>> 
>> Why do I always just use
>> 
>> on mouseDown
>>    grab me
>> end mouseDown
>> 
>> then set up a load of images as dropTargets and have stuff like this in
>> the grabbedObject:
>> 
>> on mouseUp
>>    if not within (img "target", the mouseloc) then
>>       set the loc of me to 857,673
>>    end if
>> end mouseUp
>> 
>> must be missing something.

Ray wanted to drag files onto stacks. Grab only works on objects inside a 
single stack. 

On May 9, 2013, at 2:07 PM, Scott Rossi wrote:

> Only you can know why you always use that technique, but with grab,
> there's no way to act upon events/messages while grab is active (thus you
> can't do cursor updates and provide user feedback), and you can't "grab"
> an object across stacks.

That's mostly true, Scott. The only mouse message that gets sent during a grab 
is mouseMove. So you can check location, within() and other things during the 
grab operation and act on them within the mouseMove handler. 

Devin


Devin Asay
Office of Digital Humanities
Brigham Young University


_______________________________________________
use-livecode mailing list
use-livecode@lists.runrev.com
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Reply via email to