Пример #1
0
 void FlowObject_DragDrop(object sender, DragEventArgs e)
 {
     //so link it....
     if (e.Effect == DragDropEffects.Link)
     {
         DragData   dd      = (DragData)e.Data.GetData(typeof(DragData));
         string     item    = dd.Name;
         int        flowout = dd.Flowout;
         FlowObject c       = (FlowObject)this.Parent.Controls[this.Parent.Controls.IndexOfKey(item)];
         if (dd.Flowout == 1)
         {
             c.FlowoutSide = this;
         }
         else
         {
             c.FlowOut = this;
         }
         this.Parent.Invalidate();
     }
 }