示例#1
0
 public void ClearDragEvent()
 {
     {
         if (OnDragEvent != null)
         {
             Delegate[] invokeList = OnDragEvent.GetInvocationList();
             if (invokeList != null)
             {
                 foreach (Delegate del in invokeList)
                 {
                     OnDragEvent -= (OnDragDlg)del;
                 }
             }
         }
     }
     {
         if (OnBeginDragEvent != null)
         {
             Delegate[] invokeList = OnBeginDragEvent.GetInvocationList();
             if (invokeList != null)
             {
                 foreach (Delegate del in invokeList)
                 {
                     OnBeginDragEvent -= (OnBeginDragDlg)del;
                 }
             }
         }
     }
     {
         if (OnEndDragEvent != null)
         {
             Delegate[] invokeList = OnEndDragEvent.GetInvocationList();
             if (invokeList != null)
             {
                 foreach (Delegate del in invokeList)
                 {
                     OnEndDragEvent -= (OnEndDragDlg)del;
                 }
             }
         }
     }
 }