Drag-And-Drop Image Fun

Igor Couto igor at pixelmedia.com.au
Fri May 30 21:25:01 EDT 2003

Hello, Tuviah!

Thank you so much for the feedback! - This was driving me insane!

On Thursday, May 29, 2003, at 09:10  PM, Tuviah M Snyder wrote:

> Just tested it and there seems to be a bug where dragging and dropping
> images within Rev does not work. Will fix for 2.1. This is how it was
> supposed to work:

I think you were probably typing a bit too fast :-D ... The code for 
the target image should have been:

on dragenter
   if "text" is among the items of keys(the dragData) then
     set the acceptDrop to true
   end if
end dragenter

on dragdrop
   if "text" is among the items of keys(the dragData) then
     put base64decode(the dragdata["text"]) into me
   end if
   pass dragdrop
end dragdrop

It works like a charm - for all types of images, not just PNG! However, 
it only works if dragging WITHIN Rev - not if you want to drag your 
picture to another app... The other apps now think we are dragging 

Any further hints would be IMMENSELY appreciated!

Many thanks,
Igor de Oliveira Couto
igor at pixelmedia.com.au

More information about the use-livecode mailing list