QDrop allows drag and drop of desktop files and
folders into 4D forms. It lets you build intuitive,
user-friendly interfaces for all kinds of 4D database
applications. With QDrop your software
becomes simpler and more appealing to end-users.
QDrop is available for MacOS X (Tiger or later) and Windows (XP/Vista), and is
compatible with 4D versions 2004.x to 11.x SQL or later.
QDrop offers a plug-in area that you can put
on any 4D form and use as a drop zone. The QDrop
area can be made big enough to cover the entire
form window, or it can be placed behind specific
form objects, other plug-in areas, and so on.
QDrop can easily revamp those
parts of a database that involve working with
files and folders, and is particularly suited
to image databases.
How it works
Each QDrop area can be configured to accept specific classes of files, using either filename extensions (on both platforms), or Uniform Type Identifiers (only on MacOS X). Note that 4-character
MacOS filetypes are deprecated and they should no longer be used.
Instead of specifying individual file extensions, QDrop provides special constants called "magic file types" which collectively represent entire classes of files. Magic file types are:
- any* denotes that
all files are accepted
- fold denotes that
folders are accepted
- qti* means that
all images understood by QuickTime are accepted (requires QuickTime)
- qtm* accepts all
movie formats understood by QuickTime (requires QuickTime)
If, for example, you want to use QDrop for importing
image files that you will subsequently handle
with QPix, you don't need to configure the drop
area separately for JPEG, GIF, PICT, TIFF, etc
files. Simply configure it for "qti*" and all these
types will be accepted. UTIs are also very handy for doing this (using, e.g. the "public/image" type), but they exist only on MacOS X.
Visual feedback as a result of accepted drop
actions is customizable by the developer (width,
color, inset).
Once accepted drag types are configured, the QDrop area will automatically react
to the designated objects and also:
- users will get a visual feedback that the
drag+drop is accepted
- developers will receive a drop event and
they will be able to program how the drop action
should be handled.
.