Copy cursor (including a + sign) for drag and drop in mAirListDB

I’ve recently been doing a lot of work in mAirListDB, and I’ve lost count of the number of times I’ve accidentally MOVED items from one Folder to another when my intention was to COPY the items into another Folder (by holding down Ctrl while drag/dropping). This has literally wasted hours of my time.

This would be avoided if you could implement a COPY drag cursor, which would look identical to the current MOVE cursor, but with a + sign added to the little ‘document page’ cursor used for drag/drop operations.

Thanks in advance.

BFN
CAD

I have tried to get that copy cursor working, to no avail.

Would this page:
http://www.blong.com/Conferences/BorCon2001/DragAndDrop/4114.htm#CustomisingCursor
be of any help? Scroll down to the heading ‘Customising the Drag Cursor Further.’ :wink:

BFN
CAD

No, because the example describes VCL drag&drop, while mAirList uses OLE drag&drop, which is far more complicated.

OK then, how about this?
http://pasotech.altervista.org/delphi/articolo87.htm
(The top part is in Italian but the code examples are in English! :D)

BFN
CAD

After some investigation, I found that:

  • In the way I am using it, Virtual Treeview uses both OLE and VCL drag&drop; OLE for drag&drop from outside the application (e.g. files from Windows Explorer), and VCL for drag&drop inside the application (e.g. from the playlist into a player).

  • That means that in the database application, when you drop items into a folder, VCL drag&drop is actually used.

  • Virtual Treeview provides an abstraction layer so that both VCL and OLE drag&drop events can be handled by the same set of event handlers.

  • Unfortunately, this abstraction layer hides the TDragObject object which is needed to modify the cursor to a non-standard one during VCL drag&drop (the “copy” cursor is not a standard cursor in Delphi).

Sorry, bad luck.

I could switch all internal drag operations to OLE, but that’s not “switch” as in turning a switch, but “switch” as in implementing tons of OLE interfaces to serialize the drag data into a format suitable for OLE.

Ah: I understand. :frowning:

I see why VTV would do that, but in this case, it’s a real shame that no separate copy/move cursor will be possible.

Any sort of visual feedback is VERY useful: especially when you think you are COPYing items from one Folder into another, but you are actually MOVING them. :o

Hence … Plan B! :wink:

If the mAirListDB window has a StatusBar (I’m not able to chck right now), could you write text into it while a drag operation is in progress? This would read Moving Items… or Copying Items…, depending on whether the user is holding down Ctrl or not. The text would ‘disappear’ when the operation completes (or is abandoned).

If no StatusBar is available, maybe some ‘invisible’ control on the Toolbar could ‘light up’ during a drag operation? Something like the AUTO and ASSIST buttons/indicators in a Playlist toolbar, perhaps?

What do you think?

BFN
CAD

Although more difficult to implement than a status bar update, switching to OLE drag&drop altogether seems to be the more promising approach in the long run. Because that would enable inter-application-drag&drop as well.

But not today, actually. Sorry that this software isn’t perfect in its version 3.1 :wink:

99.99% is fine by me! :smiley:

And of course (and as you said) full OLE drag/drop would be better for the long term.

I’m a patient person. 8)

BFN
CAD

Really? Sorry, I didn’t know :wink:

Usually, you implement changes so quickly that you never have a chance to find out whether I am patient or not! :smiley:

BFN
CAD