4 writes to _row
System.Windows.Forms (4)
System\Windows\Forms\Controls\DataGridView\DataGridView.HitTestInfo.cs (1)
29_row = _col = -1;
System\Windows\Forms\Controls\DataGridView\DataGridView.Methods.cs (3)
9412hti._row = GetRowIndexFromY(y, out int yRowTopEdge); 9479hti._row = GetRowIndexFromY(y, out int yRowTopEdge); 12112hti._row = lastVisibleRowIndex;
164 references to _row
System.Windows.Forms (164)
System\Windows\Forms\Controls\DataGridView\DataGridView.HitTestInfo.cs (5)
53return _row; 95value is HitTestInfo hti && _type == hti._type && _row == hti._row && _col == hti._col; 100public override int GetHashCode() => HashCode.Combine(_type, _row, _col); 107return $"{{ Type:{_type}, Column:{_col}, Row:{_row} }}";
System\Windows\Forms\Controls\DataGridView\DataGridView.Methods.cs (159)
5765hti._row, 5854hti._row, 8598&& hti._row >= 0 8599&& (Rows.GetRowState(hti._row) & DataGridViewElementStates.Frozen) == 0) 8696int firstRowIndex = hti._row >= 0 ? hti._row : Rows.GetFirstRow(DataGridViewElementStates.Visible); 9413if (hti._row < 0) 9418Debug.Assert(yRowTopEdge == GetRowYFromIndex(hti._row)); 9424int rowHeight = Rows.SharedRow(hti._row).GetHeight(hti._row); 9429if (RowIsResizable(hti._row) && AutoSizeRowsMode == DataGridViewAutoSizeRowsMode.None) 9439if (hti._row != DisplayedBandsInfo.FirstDisplayedScrollingRow || DisplayedBandsInfo.NumDisplayedFrozenRows > 0) 9441indexTmp = Rows.GetPreviousRow(hti._row, DataGridViewElementStates.Visible); 9480if (hti._col < 0 || hti._row < 0) 9486Debug.Assert(yRowTopEdge == GetRowYFromIndex(hti._row)); 9566int rowHeight = Rows.SharedRow(hti._row).GetHeight(hti._row); 9569if (RowIsResizable(hti._row) && AutoSizeRowsMode == DataGridViewAutoSizeRowsMode.None) 9578if (hti._row != DisplayedBandsInfo.FirstDisplayedScrollingRow || DisplayedBandsInfo.NumDisplayedFrozenRows > 0) 9580indexTmp = Rows.GetPreviousRow(hti._row, 9607if (hti._row == rowIndex 9656if (hti._col >= 0 && hti._row >= 0) 9668else if (_dataGridViewOper[OperationTrackCellSelect] && hti._col >= 0 && hti._row >= 0) 11907Debug.Assert(_ptMouseDownCell.Y == hti._row); 11968int rowIndex = (hti._typeInternal == DataGridViewHitTestTypeInternal.RowResizeBottom) ? hti._row : hti._adjacentRow; 12065if (_ptCurrentCell.X >= 0 && (_ptCurrentCell.X != hti._col || _ptCurrentCell.Y != hti._row)) 12070forCurrentCellChange: _ptCurrentCell.X != hti._col || _ptCurrentCell.Y != hti._row, 12071forCurrentRowChange: _ptCurrentCell.Y != hti._row)) 12103if (hti._row >= Rows.Count) 12129&& IsSharedCellSelected(Rows.SharedRow(hti._row).Cells[hti._col], hti._row) 12140RemoveIndividuallySelectedCells(hti._col, hti._row); 12165hti._row); 12169SetSelectedCellCore(hti._col, hti._row, selected: true); 12174SetSelectedCellCore(hti._col, hti._row, selected: true); 12179SetSelectedCellCore(hti._col, hti._row, selected: false); 12184hti._row, 12273hti._row, 12284&& (Columns[hti._col].Selected || IsSharedCellSelected(Rows.SharedRow(hti._row).Cells[hti._col], hti._row)) 12304SetSelectedCellCore(hti._col, hti._row, true); 12324RemoveIndividuallySelectedCells(hti._col, hti._row); 12355hti._row); 12359SetSelectedCellCore(hti._col, hti._row, true); 12374SetSelectedCellCore(hti._col, hti._row, false); 12379SetSelectedCellCore(hti._col, hti._row, false); 12385hti._row, 12395if (isControlDown && ((Rows.GetRowState(hti._row) & DataGridViewElementStates.Selected) != 0)) 12403_trackRow = hti._row; 12427if (_selectedBandIndexes[bandIndex] != hti._row) 12454if (hti._row >= _ptAnchorCell.Y) 12456SelectRowRange(_ptAnchorCell.Y, hti._row, true); 12460SelectRowRange(hti._row, _ptAnchorCell.Y, true); 12463else if ((Rows.GetRowState(hti._row) & DataGridViewElementStates.Selected) == 0) 12465Debug.Assert(_selectedBandIndexes.Contains(hti._row) == 12466((Rows.GetRowState(hti._row) & DataGridViewElementStates.Selected) != 0)); 12467SetSelectedRowCore(hti._row, true); 12472Debug.Assert(_selectedBandIndexes.Contains(hti._row)); 12473SetSelectedRowCore(hti._row, false); 12478hti._row, 12489&& (((Rows.GetRowState(hti._row) & DataGridViewElementStates.Selected) != 0) 12490|| IsSharedCellSelected(Rows.SharedRow(hti._row).Cells[hti._col], hti._row)) 12510SetSelectedCellCore(hti._col, hti._row, true); 12530RemoveIndividuallySelectedCells(hti._col, hti._row); 12561hti._row); 12565SetSelectedCellCore(hti._col, hti._row, selected: true); 12580SetSelectedCellCore(hti._col, hti._row, selected: false); 12585SetSelectedCellCore(hti._col, hti._row, false); 12591hti._row, 12764if ((hti._col != _ptCurrentCell.X || hti._row != _ptCurrentCell.Y) 12765&& !CommitEditForOperation(hti._col, hti._row, forCurrentCellChange: true)) 12774if (_ptAnchorCell.X == -1 || IsInnerCellOutOfBounds(hti._col, hti._row)) 12785hti._row); 12787if (hti._col != _ptCurrentCell.X || hti._row != _ptCurrentCell.Y) 12791hti._row, 14949OnCellDoubleClick(new DataGridViewCellEventArgs(hti._col, hti._row)); 15871&& _ptMouseDownCell.Y == hti._row 15888dgvcme = new DataGridViewCellMouseEventArgs(hti._col, hti._row, mouseX, e.Y - hti.RowY, e); 15892OnCellClick(new DataGridViewCellEventArgs(hti._col, hti._row)); 15959if (_ptMouseDownCell.X == hti._col && _ptMouseDownCell.Y == hti._row) 15972dgvcme = new DataGridViewCellMouseEventArgs(hti._col, hti._row, mouseX, e.Y - hti.RowY, e); 16047int rowIndex = (hti._typeInternal == DataGridViewHitTestTypeInternal.RowResizeBottom) ? hti._row : hti._adjacentRow; 16116_ptMouseDownCell.Y = hti._row; 16124DataGridViewCellMouseEventArgs dgvcme = new(hti._col, hti._row, mouseX, e.Y - hti.RowY, e); 16311else if (_dataGridViewOper[OperationTrackRowSelect] && hti._row >= 0) 16315else if (_dataGridViewOper[OperationTrackCellSelect] && hti._col >= 0 && hti._row >= 0) 16362dgvcme = new DataGridViewCellMouseEventArgs(hti._col, hti._row, mouseX, e.Y - hti.RowY, meTmp); 16366dgvcme = new DataGridViewCellMouseEventArgs(hti._col, hti._row, mouseX, e.Y - hti.RowY, e); 16371&& hti._row >= 0 16372&& _ptMouseDownCell.Y == hti._row 16436OnCellMouseUp(new DataGridViewCellMouseEventArgs(hti._col, hti._row, mouseX, e.Y - hti.RowY, e)); 17940if (isControlDown && ((Rows.GetRowState(hti._row) & DataGridViewElementStates.Selected) != 0)) 17948if (dataGridViewColumn is not null && hti._row != _ptCurrentCell.Y) 17958fireRowLeave: hti._row != _ptCurrentCell.Y, 17959fireRowEnter: hti._row != _ptCurrentCell.Y, 18008if (hti._row >= Rows.Count) 18035else if ((Rows.GetRowState(hti._row) & DataGridViewElementStates.Visible) == 0) 18043_trackRow = hti._row; 18068if (_selectedBandIndexes[bandIndex] != hti._row) 18104if (hti._row >= _ptAnchorCell.Y) 18106SelectRowRange(_ptAnchorCell.Y, hti._row, true); 18110SelectRowRange(hti._row, _ptAnchorCell.Y, true); 18113else if ((Rows.GetRowState(hti._row) & DataGridViewElementStates.Selected) == 0) 18115Debug.Assert(_selectedBandIndexes.Contains(hti._row) == 18116((Rows.GetRowState(hti._row) & DataGridViewElementStates.Selected) != 0)); 18117SetSelectedRowCore(hti._row, true); 18122if (hti._row != _ptCurrentCell.Y) 18124if (IsInnerCellOutOfBounds(dataGridViewColumn.Index, hti._row)) 18130bool success = ScrollIntoView(dataGridViewColumn.Index, hti._row, false); 18132if (IsInnerCellOutOfBounds(dataGridViewColumn.Index, hti._row)) 18137success = SetCurrentCellAddressCore(dataGridViewColumn.Index, hti._row, !selectRowRange, false, true); 18159Debug.Assert(_selectedBandIndexes.Contains(hti._row)); 18160SetSelectedRowCore(hti._row, false); 18399Debug.Assert(hti._row >= 0); 18403&& hti._row != _ptCurrentCell.Y 18404&& !CommitEditForOperation(_ptCurrentCell.X, hti._row, forCurrentCellChange: true)) 18410if (IsRowOutOfBounds(hti._row)) 18418if (_trackRowEdge >= _trackRow && hti._row > _trackRowEdge && _trackRowEdge >= 0) 18421hti._row, true); 18422_trackRowEdge = hti._row; 18424else if (_trackRowEdge > _trackRow && hti._row < _trackRowEdge && hti._row >= _trackRow && _trackRowEdge >= 0) 18426SelectRowRange(Rows.GetNextRow(hti._row, DataGridViewElementStates.Visible), 18428_trackRowEdge = hti._row; 18430else if (hti._row > _trackRow && _trackRowEdge == -1) 18433hti._row, true); 18434_trackRowEdge = hti._row; 18436else if (_trackRowEdge <= _trackRow && hti._row < _trackRowEdge && _trackRowEdge >= 0) 18438SelectRowRange(hti._row, 18441_trackRowEdge = hti._row; 18443else if (_trackRowEdge < _trackRow && hti._row > _trackRowEdge && hti._row <= _trackRow && _trackRowEdge >= 0) 18446Rows.GetPreviousRow(hti._row, DataGridViewElementStates.Visible), 18448_trackRowEdge = hti._row; 18450else if (hti._row < _trackRow && _trackRowEdge == -1) 18452SelectRowRange(hti._row, 18455_trackRowEdge = hti._row; 18457else if (_trackRowEdge > _trackRow && hti._row < _trackRow) 18461SelectRowRange(hti._row, 18464_trackRowEdge = hti._row; 18466else if (hti._row > _trackRow && _trackRowEdge < _trackRow && _trackRowEdge >= 0) 18472hti._row, true); 18473_trackRowEdge = hti._row; 18481if (_ptCurrentCell.Y != -1 && hti._row != _ptCurrentCell.Y) 18483if (IsRowOutOfBounds(hti._row)) 18489hti._row, 29161if (_ptMouseEnteredCell.X != htiToUse._col || _ptMouseEnteredCell.Y != htiToUse._row) 29173dgvce = new DataGridViewCellEventArgs(htiToUse._col, htiToUse._row); 29185DataGridViewCellMouseEventArgs dgvcme = new(htiToUse._col, htiToUse._row, mouseX, e.Y - htiToUse.RowY, e); 29880if (hti._row >= 0) 29891if (hti._col >= 0 && hti._row >= 0) 29899if (_dataGridViewOper[OperationTrackRowSelect] && hti._row >= 0) 29903else if (_dataGridViewOper[OperationTrackCellSelect] && hti._col >= 0 && hti._row >= 0) 29977dataGridViewCell = Rows.SharedRow(hti._row).Cells[hti._col]; 29980Debug.Assert(hti._row == -1); 29985dataGridViewCell = Rows.SharedRow(hti._row).HeaderCell; 29988Debug.Assert(hti._row == -1); 29995? dataGridViewCell.GetInheritedContextMenuStrip(hti._row)