Пример #1
0
        private void TabPanel_DragDrop(object sender, DragEventArgs e)
        {
            //fixme:カッコカリ 範囲外にドロップすると端に行く

            Point mp = TabPanel.PointToClient(new Point(e.X, e.Y));

            var item = TabPanel.GetChildAtPoint(mp);

            int index = TabPanel.Controls.GetChildIndex(item, false);

            TabPanel.Controls.SetChildIndex((System.Windows.Forms.Control)e.Data.GetData(typeof(ImageLabel)), index);

            TabPanel.Invalidate();
        }