예제 #1
0
 private void DGV_CellMouseEnter(object sender, DataGridViewCellEventArgs e)
 {
     if ((0 <= e.RowIndex) && ((e.ColumnIndex == OUTPUTFILENAME_COLUMN_INDEX) || (e.ColumnIndex == OUTPUTDIRECTORY_COLUMN_INDEX)) &&
         DGV.Rows[e.RowIndex].Selected && !_Model[e.RowIndex].IsFinished())
     {
         DGV.SetHandCursorIfNonHand();
     }
     else
     {
         DGV.SetDefaultCursorIfHand();
     }
 }
예제 #2
0
        private void DGV_SelectionChanged(object sender, EventArgs e)
        {
            _UserMade_DGV_SelectionChanged = true;
            var selectedDownloadRow = this.GetSelectedDownloadRow();

            SelectionChanged?.Invoke(selectedDownloadRow);

            if ((selectedDownloadRow != null) && !selectedDownloadRow.IsFinished())
            {
                var pt = DGV.PointToClient(Control.MousePosition);
                var ht = DGV.HitTest(pt.X, pt.Y);
                switch (ht.ColumnIndex)
                {
                case OUTPUTFILENAME_COLUMN_INDEX:
                case OUTPUTDIRECTORY_COLUMN_INDEX:
                    DGV.SetHandCursorIfNonHand();
                    break;
                }
            }
        }