text field in modal allows no input
Trevor DeVore
lists at mangomultimedia.com
Mon Apr 18 07:22:04 EDT 2011
On Sat, Apr 16, 2011 at 11:26 AM, Maarten Koopmans <
maarten.koopmans at gmail.com> wrote:
> I have a main stack that accepts a drag-drop for files like this on a
> hidden
> field the size of the card:
>
> *on* dragDrop
>
> *if* the dragData["files"] is not empty *then*
>
> *modal* stack "AddMetaData"
>
> addFiles(dragData["files"])
>
> *end* *if*
>
> *set* the dragAction to link
>
> *pass* dragDrop
>
> *end* dragDrop'
>
You might try processing the files outside of the drag event.
Change:
modal stack "AddMetaData"
addFiles(dragData["files"])
To:
put the dragData["files"] into theFiles
send "ProcessDrop theFiles" to me in 0 milliseconds
And add:
on ProcessDrop pFiles
modal stack "AddMetaData"
addFiles pFiles
end ProcessDrop
One thing to note is that it is possible for dragData["files"] to disappear
after a drag and drop operation. I have seen graphics applications that make
a file available during drag and drop but then delete it when the drag and
drop operation is complete. In this scenario you need to copy the files to a
new location in dragDrop and then process the copies outside of the drag and
drop operation. This scenario is probably rare though.
Even if this solves the problem I would recommend filing a bug report so the
issue can possibly be fixed in the future.
--
Trevor DeVore
Blue Mango Learning Systems
LiveCode Resources for Developers: http://livecode.bluemangolearning.com
Get SQL Yoga as part of the Omegabundle for LiveCode 2011: Save 85% on
essential tools for LiveCode development - omegabundle.com.
More information about the use-livecode
mailing list