DragDropEffects

  • Thread starter Thread starter #Hai
  • Start date Start date
H

#Hai

Hi,
I'm trying to deal with drag drop technique and get into trouble with
DragDropEffect:
DragDropEffects.Link and DragDropEffects.Scroll. The explanations of MSDN
about them are short and vague:
Link - The data from the drag source is linked to the drop target.
ScrollScrolling - is about to start or is currently occurring in the drop
target.
Can anyone give me a more detail comments about such constants ?

Any help will be appreciated.
 
Hi Hai,
DragDropEffect give info about what is going to happen if the user drop the
objects on the targed window. They are used mutually used. First the source
tells any potential target which operations are allowable using the
allowedEffects parameter of the DoDragDrop method. And then the targed tells
the source what is going to happen if the user drop the data or it tells
what the user has done (the return value of DoDragDrop). The source uses
drop effects to change the mouse cursor according to the current status of
the operation.
Actually if the source doesn't want to provide some special cursors the only
value which it should take care of is DragDropEffect.Move when it comes as a
return value of DoDragDrop method, be cause it has to delete the object from
its data.
DragDropEffect.Link is the same link operation which is part of OLE (object
linking and embedding). Anyway I don't know a person, who uses this.
DragDropEffects.Scroll should be be set by the target whenever the mouse
cursor is in the "auto scroll" portion of its view (it is scrolling the
view). It should be received in GiveFeedback event only in order the source
to set appropriate cursor for scrolling. I beleave it is senseless to have
this as a return value of DoDragDrop method and if you do I think it should
be considered as a operation cancelation.

HTH
b/rgds
100
 
Back
Top