person

person

  • NA
  • 96
  • 0

Drag and drop

Sep 17 2009 11:50 AM
Hi,

I have a reasonably complex grid coded at the moment. It consists of rows of canvas' and inside these canvas' (foreach row) there are many canvas' that are different hieghts and widths and are spaced differently.

I have coded the drag functionality fine, using adorners with overlay elements.......however the drop part is slightly harder.
Each individual canvas in the row canvas' has its own object bound to it. So i basically want to drag one of these and drop it on to another, though when it is dropped the object of the target will be swapped with the object from the source.
Each canvas doesnt no what line its on, the columns serve no purpose here either, as i add all line canvas' to column 0 and span the other columns.

This may not be the layout, however this is the way it is done, so I have to find a work around for the drop part.

Any ideas on how to create a drop 'window' over the target or something similar would be greatly appreciated.

Thanks in advnace.

Urema.

Answers (1)