Exemplo n.º 1
0
 void panel_MouseDown(object sender, MouseEventArgs e)
 {
     if (sender.GetType() == typeof(SmallButtonControl))
     {
         SmallButtonControl btnSamll = sender as SmallButtonControl;
         PanelControl       panel    = btnSamll.Parent as PanelControl;
         panel.DoDragDrop(panel, DragDropEffects.Move);
     }
     else if (sender.GetType() == typeof(LargeButtonControl))
     {
         LargeButtonControl btnLarge = sender as LargeButtonControl;
         PanelControl       panel    = btnLarge.Parent as PanelControl;
         panel.DoDragDrop(panel, DragDropEffects.Move);
     }
 }