cc042297
asked on
Delphi like drag & drop
Hi,
I would like to make drag & drop work in my app the same way as in the Delphi IDE: It displays a transparent rectangle which has the size of dragged object, instead of moving the object itself.
Any help is appreciated.
Regards,
CC
I would like to make drag & drop work in my app the same way as in the Delphi IDE: It displays a transparent rectangle which has the size of dragged object, instead of moving the object itself.
Any help is appreciated.
Regards,
CC
ASKER
Hi Shane,
It could be anything on the form, a control, a picture, which needs to be draged at runtime. The question is not really about drag & drop mechanism, but about showing a semitransparent dragimage (with the size of the draged object). There is a "Jedi" control which can be moved and resized on the screen at runtime, but it simply moves the control while it is dragged. Because of this it blinks and leaves "footprints" behind.
It could be anything on the form, a control, a picture, which needs to be draged at runtime. The question is not really about drag & drop mechanism, but about showing a semitransparent dragimage (with the size of the draged object). There is a "Jedi" control which can be moved and resized on the screen at runtime, but it simply moves the control while it is dragged. Because of this it blinks and leaves "footprints" behind.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
correction:
2. If the dragging takes place from another application, you have limited options over the drag shape.
2. If the dragging takes place from another application, you have limited options over the drag shape.
CC,
Are you still with us?
Are you still with us?
ASKER
aikimark
Thanx for reminding me! :)
I tried to do it Shane's way. Spent some time on learning how Delphi handles drag and drop. If I'm not mistaken there is a problem with it. But I’m not sure yet. I didn't want to say anything till I'm not certain. Right now I have other things to do, but I will be back as soon as I can. :)
Regards,
CC
Thanx for reminding me! :)
I tried to do it Shane's way. Spent some time on learning how Delphi handles drag and drop. If I'm not mistaken there is a problem with it. But I’m not sure yet. I didn't want to say anything till I'm not certain. Right now I have other things to do, but I will be back as soon as I can. :)
Regards,
CC
ASKER
Well, after checking all avaible Delphi sources I have come to conclusion that it is not possible to dot it by using D&D offered by Delphi & Windows. The code which displays the Drag image is in Windows and there is no way I can make it work the way I wanted. At least I did not find any. So finally I have built my own Drag&Drop from the bottom. Took me much less time then what I had previously spent on trying to do it the Delphi & Windows way.
I still appreciate your help, so the points will be splitted.
Thanx, CC.
I still appreciate your help, so the points will be splitted.
Thanx, CC.
ASKER
I have come to conclusion -> I have come to the conclusion :)
Shane