1 write to ptCurrentCell
System.Windows.Forms (1)
winforms\Managed\System\WinForms\DataGridView.cs (1)
517this.ptCurrentCell = new Point(-1, -1);
945 references to ptCurrentCell
System.Windows.Forms (945)
winforms\Managed\System\WinForms\DataGridView.cs (49)
1480if (this.ptCurrentCell.X != -1 /*&& !this.IsCurrentCellInEditMode*/ && ColumnEditable(this.ptCurrentCell.X)) 1485if (!IsSharedCellReadOnly(dataGridViewCell, this.ptCurrentCell.Y)) 2180if (this.ptCurrentCell.X == -1 && this.ptCurrentCell.Y == -1) 2184Debug.Assert(this.ptCurrentCell.X >= 0 && ptCurrentCell.Y >= 0); 2185Debug.Assert(this.ptCurrentCell.X < this.Columns.Count); 2186Debug.Assert(this.ptCurrentCell.Y < this.Rows.Count); 2187DataGridViewRow dataGridViewRow = (DataGridViewRow) this.Rows[this.ptCurrentCell.Y]; // unsharing row 2188return dataGridViewRow.Cells[this.ptCurrentCell.X]; 2192if ((value != null && (value.RowIndex != this.ptCurrentCell.Y || value.ColumnIndex != this.ptCurrentCell.X)) || 2193(value == null && this.ptCurrentCell.X != -1)) 2241return this.ptCurrentCell; 2249Debug.Assert(this.ptCurrentCell.X >= 0 && this.ptCurrentCell.X < this.Columns.Count); 2250Debug.Assert(this.ptCurrentCell.Y >= 0 && this.ptCurrentCell.Y < this.Rows.Count); 2251DataGridViewRow dataGridViewRow = this.Rows.SharedRow(this.ptCurrentCell.Y); 2253DataGridViewCell dataGridViewCell = dataGridViewRow.Cells[this.ptCurrentCell.X]; 2254Debug.Assert(this.IsSharedCellVisible(dataGridViewCell, this.ptCurrentCell.Y)); 2263if (this.ptCurrentCell.X == -1) 2267Debug.Assert(this.ptCurrentCell.Y != -1); 2269bool previousVisibleColumnExists = (null != this.Columns.GetPreviousColumn(this.Columns[this.ptCurrentCell.X], DataGridViewElementStates.Visible, DataGridViewElementStates.None)); 2270bool previousVisibleRowExists = (-1 != this.Rows.GetPreviousRow(this.ptCurrentCell.Y, DataGridViewElementStates.Visible)); 2280if (this.ptCurrentCell.X == -1) 2285Debug.Assert(this.ptCurrentCell.Y != -1); 2287bool nextVisibleColumnExists = (null != this.Columns.GetNextColumn(this.Columns[this.ptCurrentCell.X], DataGridViewElementStates.Visible, DataGridViewElementStates.None)); 2288bool nextVisibleRowExists = (-1 != this.Rows.GetNextRow(this.ptCurrentCell.Y, DataGridViewElementStates.Visible)); 2298if (this.ptCurrentCell.X == -1) 2303Debug.Assert(this.ptCurrentCell.Y != -1); 2319if (this.ptCurrentCell.X == -1) 2324Debug.Assert(this.ptCurrentCell.Y >= 0); 2325Debug.Assert(this.ptCurrentCell.Y < this.Rows.Count); 2327return this.Rows[this.ptCurrentCell.Y]; 3130if (this.ptCurrentCell.X >= 0 && 3206if (this.ptCurrentCell.X >= 0 && 3445!this.Columns[this.ptCurrentCell.X].Frozen && 3582if (this.ptCurrentCell.X == -1) 3587return this.CurrentCellInternal.GetInheritedStyleInternal(this.ptCurrentCell.Y); 3666if (this.RowHeadersVisible && this.ShowEditingIcon && this.ptCurrentCell.Y >= 0) 3669InvalidateCellPrivate(-1, this.ptCurrentCell.Y); 3921this.ptCurrentCell.X != -1 && 4001if (this.ptCurrentCell.X != -1 && 4900Debug.Assert(this.ptCurrentCell.Y >= 0); 4901InvalidateCellPrivate(-1, this.ptCurrentCell.Y); 4907Debug.Assert(this.ptCurrentCell.Y >= 0); 4908InvalidateCellPrivate(-1, this.ptCurrentCell.Y);
winforms\Managed\System\WinForms\DataGridViewMethods.cs (896)
2593if (this.ptCurrentCell.X == -1) 2615Debug.Assert(this.ptCurrentCell.X >= 0 && this.ptCurrentCell.X < this.Columns.Count); 2616Debug.Assert(this.ptCurrentCell.Y >= 0 && this.ptCurrentCell.Y < this.Rows.Count); 2622if (IsSharedCellReadOnly(dataGridViewCell, this.ptCurrentCell.Y) || 2623!ColumnEditable(this.ptCurrentCell.X)) 2639DataGridViewCellCancelEventArgs dgvcce = new DataGridViewCellCancelEventArgs(this.ptCurrentCell.X, this.ptCurrentCell.Y); 2647if (this.ptCurrentCell.X > -1) 2655if (IsSharedCellReadOnly(dataGridViewCell, this.ptCurrentCell.Y) || 2656!ColumnEditable(this.ptCurrentCell.X)) 2678DataGridViewCellStyle dataGridViewCellStyle = dataGridViewCell.GetInheritedStyle(null, this.ptCurrentCell.Y, true); 2722((IDataGridViewEditingControl)this.editingControl).EditingControlRowIndex = this.ptCurrentCell.Y; 2741if (this.toolTipControl.Activated && this.ptToolTipCell == this.ptCurrentCell) 2758InvalidateCellPrivate(this.ptCurrentCell.X, this.ptCurrentCell.Y); 3071if (this.ptCurrentCell.X != -1) 3073Debug.Assert(this.ptCurrentCell.Y != -1); 3075int oldCurrentCellX = this.ptCurrentCell.X; 3134dgvdee2 = new DataGridViewDataErrorEventArgs(exception, this.ptCurrentCell.X, 3135this.ptCurrentCell.Y, 3159InvalidateCellPrivate(this.ptCurrentCell.X, this.ptCurrentCell.Y); 3163else if (this.ptCurrentCell.X == -1 && this.Focused) 3245int oldCurrentCellX = this.ptCurrentCell.X; 3250if (currentCellDirty || this.ptCurrentCell.Y == -1 || this.ptCurrentCell.X == -1) 3276if (this.ptCurrentCell.Y > -1) 3278InvalidateRowPrivate(this.ptCurrentCell.Y); 3282DataGridViewCellStyle dataGridViewCellStyle = dataGridViewCell.GetInheritedStyle(null, this.ptCurrentCell.Y, true); 3298if (discardNewRow && this.ptCurrentCell.Y == this.newRowIndex - 1) 3307this.ptCurrentCell.Y == this.newRowIndex - 1 && 3347if (this.ptCurrentCell.X > -1) 3396if (this.dataConnection.CurrencyManager.Count <= this.ptCurrentCell.Y) 3466if (this.ptCurrentCell.X != -1 && 3470InvalidateCellPrivate(this.ptCurrentCell.X, -1); 3800Debug.Assert(this.ptCurrentCell.X > -1); 3803if (this.ptCurrentCell.X == -1) 3807OnCellLeave(ref dataGridViewCurrentCell, this.ptCurrentCell.X, this.ptCurrentCell.Y); 3811if (this.ptCurrentCell.X == -1) 3815OnRowLeave(ref dataGridViewCurrentCell, this.ptCurrentCell.X, this.ptCurrentCell.Y); 3825if (this.ptCurrentCell.X > -1 && this.ptCurrentCell.Y > -1) 3827InvalidateCellPrivate(this.ptCurrentCell.X /*columnIndex*/, this.ptCurrentCell.Y /*rowIndex*/); 3834if (this.ptCurrentCell.X == -1) 3838if (OnCellValidating(ref dataGridViewCurrentCell, this.ptCurrentCell.X, this.ptCurrentCell.Y, context)) 3842if (this.ptCurrentCell.X == -1) 3846OnRowEnter(ref dataGridViewCurrentCell, this.ptCurrentCell.X, this.ptCurrentCell.Y, true /*canCreateNewRow*/, true /*validationFailureOccurred*/); 3850if (this.ptCurrentCell.X == -1) 3854OnCellEnter(ref dataGridViewCurrentCell, this.ptCurrentCell.X, this.ptCurrentCell.Y); 3856if (this.ptCurrentCell.X == -1) 3861this.ptCurrentCell.X, 3862this.ptCurrentCell.Y, 3872if (this.ptCurrentCell.X == -1) 3876OnCellValidated(ref dataGridViewCurrentCell, this.ptCurrentCell.X, this.ptCurrentCell.Y); 3881if (this.ptCurrentCell.X == -1 || !this.IsCurrentCellInEditMode) 3900Debug.Assert(this.ptCurrentCell.X > -1); 3901if (this.ptCurrentCell.X == -1) 3905if (OnCellValidating(ref dataGridViewCurrentCell, this.ptCurrentCell.X, this.ptCurrentCell.Y, context)) 3907if (this.ptCurrentCell.X == -1) 3912this.ptCurrentCell.X, 3913this.ptCurrentCell.Y, 3935if (this.ptCurrentCell.X == -1) 3940this.ptCurrentCell.X, 3941this.ptCurrentCell.Y, 3973if (this.ptCurrentCell.X == -1) 3977OnCellValidated(ref dataGridViewCurrentCell, this.ptCurrentCell.X, this.ptCurrentCell.Y); 4031Debug.Assert(this.ptCurrentCell.X > -1); 4032if (this.ptCurrentCell.X == -1) 4036int columnIndex = this.ptCurrentCell.X; 4037int rowIndex = this.ptCurrentCell.Y; 4070this.ptCurrentCell.Y != rowIndex /*fireRowLeave*/, 4071this.ptCurrentCell.Y != rowIndex /*fireRowEnter*/, 4079if (this.ptCurrentCell.Y != rowIndex && this.ptCurrentCell.Y != -1) 4082int columnIndexTmp = this.ptCurrentCell.X; 4083int rowIndexTmp = this.ptCurrentCell.Y; 4123this.ptCurrentCell.Y != rowIndex /*forCurrentRowChange*/)) 4143this.ptCurrentCell.X == -1 && 5488Debug.Assert(this.ptCurrentCell.Y == this.newRowIndex); 5799Debug.Assert(this.ptCurrentCell.X != -1); 5985Debug.Assert(this.ptCurrentCell.X != -1); 5996Debug.Assert(this.ptCurrentCell.X != -1); 6207if (this.ptCurrentCell.X == -1) 6215int curRowIndex = this.ptCurrentCell.Y; 6216int curColIndex = this.ptCurrentCell.X; 6249if (curRowIndex != this.ptCurrentCell.Y || curColIndex != this.ptCurrentCell.X) 6273InvalidateCellPrivate(this.ptCurrentCell.X, this.ptCurrentCell.Y); 6294InvalidateCellPrivate(this.ptCurrentCell.X, this.ptCurrentCell.Y); 8890(this.ptCurrentCell.Y != -1 && (this.Rows.GetRowState(this.ptCurrentCell.Y) & DataGridViewElementStates.Frozen) == 0) 8950(this.ptCurrentCell.X != -1 && !this.Columns[this.ptCurrentCell.X].Frozen) 9842this.uneditedFormattedValue = dataGridViewCell.GetFormattedValue(this.ptCurrentCell.Y, ref dataGridViewCellStyle, DataGridViewDataErrorContexts.Formatting); 9853Debug.Assert(this.ptCurrentCell.X == dataGridViewCell.ColumnIndex); 9854dataGridViewCell = this.Rows[this.ptCurrentCell.Y].Cells[this.ptCurrentCell.X]; // unshare the edited cell 9866dgvdee = new DataGridViewDataErrorEventArgs(exception, this.ptCurrentCell.X, 9867this.ptCurrentCell.Y, 9893object initialFormattedValue = dataGridViewCell.GetFormattedValue(this.ptCurrentCell.Y, ref dataGridViewCellStyle, DataGridViewDataErrorContexts.Formatting); 9898dataGridViewCell.InitializeEditingControl(this.ptCurrentCell.Y, initialFormattedValue, dataGridViewCellStyle); 9907dgvdee = new DataGridViewDataErrorEventArgs(exception, this.ptCurrentCell.X, 9908this.ptCurrentCell.Y, 10284this.ptCurrentCell.X != -1) 10693Debug.Assert(this.ptCurrentCell.X >= 0 && this.ptCurrentCell.X < this.Columns.Count); 10694Debug.Assert(this.ptCurrentCell.Y >= 0 && this.ptCurrentCell.Y < this.Rows.Count); 12424if (this.ptCurrentCell.X == -1) 12440if (this.ptCurrentCell.X >= 0 && 12441(this.ptCurrentCell.X != hti.col || this.ptCurrentCell.Y != hti.row)) 12443Point ptOriginalCurrentCell = this.ptCurrentCell; 12445this.ptCurrentCell.X != hti.col || this.ptCurrentCell.Y != hti.row /*forCurrentCellChange*/, 12446this.ptCurrentCell.Y != hti.row /*forCurrentRowChange*/)) 12451if (this.ptCurrentCell != ptOriginalCurrentCell) 12463if (this.ptCurrentCell.X == -1 && dataGridViewLastVisibleColumn != null) 12478if (this.ptCurrentCell.X == -1 && lastVisibleRowIndex != -1) 12521int oldEdgeColumnIndex = this.ptCurrentCell.X; 12522int oldEdgeRowIndex = this.ptCurrentCell.Y; 12686int oldEdgeColumnIndex = this.ptCurrentCell.X; 12687int oldEdgeRowIndex = this.ptCurrentCell.Y; 12866int oldEdgeColumnIndex = this.ptCurrentCell.X; 12867int oldEdgeRowIndex = this.ptCurrentCell.Y; 13134int oldEdgeColumnIndex = this.ptCurrentCell.X; 13135int oldEdgeRowIndex = this.ptCurrentCell.Y; 13136if ((hti.col != this.ptCurrentCell.X || hti.row != this.ptCurrentCell.Y) && 13151if (hti.col != this.ptCurrentCell.X || hti.row != this.ptCurrentCell.Y) 13185this.ptCurrentCell.X == dataGridViewCell.ColumnIndex && 13186this.ptCurrentCell.Y == dataGridViewCell.RowIndex && 13193ColumnEditable(this.ptCurrentCell.X) && 14178if (rowIndex > -1 && hti.col != this.ptCurrentCell.X) 14181int oldCurrentCellX = this.ptCurrentCell.X; 14182int oldCurrentCellY = this.ptCurrentCell.Y; 14187rowIndex != this.ptCurrentCell.Y /*fireRowLeave*/, 14188rowIndex != this.ptCurrentCell.Y /*fireRowEnter*/, 14304if (hti.col != this.ptCurrentCell.X) 14319else if (-1 != this.ptCurrentCell.X) 14322bool success = SetCurrentCellAddressCore(this.ptCurrentCell.X, this.ptCurrentCell.Y, false /*setAnchorCellAddress*/, false /*validateCurrentCell*/, false /*throughMouseClick*/); 14599if (this.ptCurrentCell.X != -1 && 14600hti.col != this.ptCurrentCell.X && 14601!CommitEditForOperation(hti.col, this.ptCurrentCell.Y, true)) 14682if (this.ptCurrentCell.X != -1 && hti.col != this.ptCurrentCell.X) 14684if (this.ptCurrentCell.Y == -1 || IsColumnOutOfBounds(hti.col)) 14689this.ptCurrentCell.Y, 14899dataGridViewColumn.Index == this.ptCurrentCell.X && 14905ColumnEditable(this.ptCurrentCell.X) && 14906(this.Rows.GetRowState(this.ptCurrentCell.Y) & DataGridViewElementStates.ReadOnly) == 0 && 14980PositionEditingControl(this.ptCurrentCell.X != e.Column.Index, true, false); 15010(columnIndex == this.ptCurrentCell.X && rowIndex == this.ptCurrentCell.Y)))) 15041Debug.Assert(this.ptCurrentCell.Y >= 0); 15042InvalidateCellPrivate(-1, this.ptCurrentCell.Y); 15044if (this.IsCurrentCellDirty && this.newRowIndex == this.ptCurrentCell.Y) 15209else if (dataGridViewColumn.Visible && this.ptCurrentCell.X == dataGridViewColumn.Index) 15228if (this.ptCurrentCell.X == dataGridViewColumn.Index && 15267if (elementState == DataGridViewElementStates.Visible && this.ptCurrentCell.Y == rowIndex) 15275Debug.Assert(this.dataConnection.CurrencyManager.Position == this.ptCurrentCell.Y); 15287if (this.ptCurrentCell.Y == rowIndex && 15324if (this.ptCurrentCell.X == dataGridViewCell.ColumnIndex && 15325this.ptCurrentCell.Y == dataGridViewCell.RowIndex && 15469this.ptCurrentCell.X > -1 && 15528if (this.ptCurrentCell.X > -1) 15533OnRowEnter(ref dataGridViewCell, this.ptCurrentCell.X, this.ptCurrentCell.Y, false /*canCreateNewRow*/, false /*validationFailureOccurred*/); 15534if (this.ptCurrentCell.X == -1) 15538OnCellEnter(ref dataGridViewCell, this.ptCurrentCell.X, this.ptCurrentCell.Y); 15543InvalidateCellPrivate(this.ptCurrentCell.X, -1); 15552if (this.ptCurrentCell.X > -1 && 15559if (this.ptCurrentCell.X > -1 && this.CurrentCellInternal.EditType == null && !this.dataGridViewOper[DATAGRIDVIEWOPER_inMouseDown]) 15564InvalidateCellPrivate(this.ptCurrentCell.X /*columnIndex*/, this.ptCurrentCell.Y /*rowIndex*/); 15573InvalidateCellPrivate(this.ptCurrentCell.X /*columnIndex*/, this.ptCurrentCell.Y /*rowIndex*/); 15691if (this.ptCurrentCell.X != -1) 15693InvalidateCell(this.ptCurrentCell.X, this.ptCurrentCell.Y); 15700this.ptCurrentCell.X > -1) 15705AccessibilityNotifyCurrentCellChanged(this.ptCurrentCell); 15730if (this.ptCurrentCell.X == -1) 15736ScrollIntoView(this.ptCurrentCell.X, this.ptCurrentCell.Y, false /*forCurrentCellChange*/); 15772Debug.Assert(this.ptCurrentCell.X == -1); 15809Debug.Assert(this.ptCurrentCell.X == -1); 15848Debug.Assert(this.ptCurrentCell.X == -1); 15894if (this.ptCurrentCell.X != -1) 15896newCurrentCell = new Point(columnIndexInserted <= this.ptCurrentCell.X ? this.ptCurrentCell.X + 1 : this.ptCurrentCell.X, 15897this.ptCurrentCell.Y); 16006if (this.ptCurrentCell.Y != -1 && rowIndexInserted <= this.ptCurrentCell.Y) 16008newCurrentCell = new Point(this.ptCurrentCell.X, this.ptCurrentCell.Y + insertionCount); 16080if (this.ptCurrentCell.Y != -1 && rowIndexInserted <= this.ptCurrentCell.Y) 16082newCurrentCell = new Point(this.ptCurrentCell.X, this.ptCurrentCell.Y + dataGridViewRows.Length); 16142if (this.ptCurrentCell.X != -1) 16146if (dataGridViewCell.KeyDownUnsharesRowInternal(e, this.ptCurrentCell.Y)) 16148DataGridViewRow dataGridViewRow = this.Rows[this.ptCurrentCell.Y]; 16149this.CurrentCellInternal.OnKeyDownInternal(e, this.ptCurrentCell.Y); 16153dataGridViewCell.OnKeyDownInternal(e, this.ptCurrentCell.Y); 16200if (this.ptCurrentCell.X != -1) 16204if (dataGridViewCell.KeyPressUnsharesRowInternal(e, this.ptCurrentCell.Y)) 16206DataGridViewRow dataGridViewRow = this.Rows[this.ptCurrentCell.Y]; 16207this.CurrentCellInternal.OnKeyPressInternal(e, this.ptCurrentCell.Y); 16211dataGridViewCell.OnKeyPressInternal(e, this.ptCurrentCell.Y); 16234if (this.ptCurrentCell.X != -1) 16238if (dataGridViewCell.KeyUpUnsharesRowInternal(e, this.ptCurrentCell.Y)) 16240DataGridViewRow dataGridViewRow = this.Rows[this.ptCurrentCell.Y]; 16241this.CurrentCellInternal.OnKeyUpInternal(e, this.ptCurrentCell.Y); 16245dataGridViewCell.OnKeyUpInternal(e, this.ptCurrentCell.Y); 16273if (this.ptCurrentCell.X > -1 && !this.dataGridViewState1[DATAGRIDVIEWSTATE1_leavingWithTabKey]) 16276OnCellLeave(ref dataGridViewCell, this.ptCurrentCell.X, this.ptCurrentCell.Y); 16277if (this.ptCurrentCell.X == -1) 16281OnRowLeave(ref dataGridViewCell, this.ptCurrentCell.X, this.ptCurrentCell.Y); 16289if (this.ptCurrentCell.X > -1 && this.ptCurrentCell.Y > -1) 16291InvalidateCellPrivate(this.ptCurrentCell.X /*columnIndex*/, this.ptCurrentCell.Y /*rowIndex*/); 16306if (this.ptCurrentCell.X != -1) 16308InvalidateCell(this.ptCurrentCell.X, this.ptCurrentCell.Y); 16331(this.ptMouseDownCell.X == this.ptCurrentCell.X && 16332this.ptMouseDownCell.Y == this.ptCurrentCell.Y))) 16949if (this.ptCurrentCell.X >= 0 && 16990if (this.ptCurrentCell.X >= 0 && 17312this.ptCurrentCell.X != -1 && 17313ColumnEditable(this.ptCurrentCell.X) && 17317!this.Rows[this.ptCurrentCell.Y].Cells[this.ptCurrentCell.X].ReadOnly) // Unshares the row 17351Debug.Assert(this.ptCurrentCell.X == -1); 17401Debug.Assert(this.ptCurrentCell.X == -1); 17481if (this.ptCurrentCell.X != -1) 17483int newX = this.ptCurrentCell.X; 17484if (columnIndex == this.ptCurrentCell.X) 17524else if (columnIndex < this.ptCurrentCell.X) 17526newX = this.ptCurrentCell.X - 1; 17528newCurrentCell = new Point(newX, (newX == -1) ? -1 : this.ptCurrentCell.Y); 17529if (columnIndex == this.ptCurrentCell.X) 17696if (this.ptCurrentCell.Y != -1 && rowIndexDeleted <= this.ptCurrentCell.Y) 17699if (rowIndexDeleted == this.ptCurrentCell.Y) 17733Debug.Assert(rowIndexDeleted < this.ptCurrentCell.Y); 17734newY = this.ptCurrentCell.Y - 1; 17736newCurrentCell = new Point(this.ptCurrentCell.X, newY); 17737if (rowIndexDeleted == this.ptCurrentCell.Y) 17843if (this.ptCurrentCell.X == dataGridViewRow.Index && 17844this.ptCurrentCell.Y == columnIndex) 17848this.ptCurrentCellCache.X = this.ptCurrentCell.X; 17849this.ptCurrentCellCache.Y = this.ptCurrentCell.Y; 17981this.ptCurrentCell.X == -1 && allowSettingCurrentCell && !this.InSortOperation) 18433if (dataGridViewColumn != null && hti.row != this.ptCurrentCell.Y) 18435int oldCurrentCellX = this.ptCurrentCell.X; 18436int oldCurrentCellY = this.ptCurrentCell.Y; 18442hti.row != this.ptCurrentCell.Y /*fireRowLeave*/, 18443hti.row != this.ptCurrentCell.Y /*fireRowEnter*/, 18484if (this.ptCurrentCell.X == -1 && lastVisibleRowIndex != -1) 18586if (hti.row != this.ptCurrentCell.Y) 18602else if (-1 != this.ptCurrentCell.Y) 18605bool success = SetCurrentCellAddressCore(this.ptCurrentCell.X, this.ptCurrentCell.Y, 18941if (this.ptCurrentCell.Y != -1 && 18942hti.row != this.ptCurrentCell.Y && 18943!CommitEditForOperation(this.ptCurrentCell.X, hti.row, true)) 19019if (this.ptCurrentCell.Y != -1 && hti.row != this.ptCurrentCell.Y) 19025bool success = SetCurrentCellAddressCore(this.ptCurrentCell.X, 19213rowIndex == this.ptCurrentCell.Y && 19220!this.Columns[this.ptCurrentCell.X].ReadOnly && 19221ColumnEditable(this.ptCurrentCell.X) && 19234if (-1 != this.ptCurrentCell.X && dataGridViewRow.Index == this.ptCurrentCell.Y && this.editingControl != null) 19534if (-1 != this.ptCurrentCell.X) 19537bool success = SetCurrentCellAddressCore(this.ptCurrentCell.X, this.ptCurrentCell.Y, 19628if (this.ptCurrentCell.X >= 0) 19631if (OnRowValidating(ref dataGridViewCellTmp, this.ptCurrentCell.X, this.ptCurrentCell.Y)) 19637if (this.ptCurrentCell.X == -1) 19641OnRowValidated(ref dataGridViewCellTmp, this.ptCurrentCell.X, this.ptCurrentCell.Y); 19644this.ptCurrentCell.X >= 0 && 19646this.newRowIndex == this.ptCurrentCell.Y) 19649int rowIndex = this.Rows.GetPreviousRow(this.ptCurrentCell.Y, DataGridViewElementStates.Visible); 19652bool success = SetAndSelectCurrentCellAddress(this.ptCurrentCell.X, rowIndex, 20362int leftEdge = GetColumnXFromIndex(this.ptCurrentCell.X); 20365leftEdge -= this.Columns[this.ptCurrentCell.X].Width-1; 20367Rectangle cellBounds = new Rectangle(leftEdge, GetRowYFromIndex(this.ptCurrentCell.Y), 20368this.Columns[this.ptCurrentCell.X].Width, this.Rows.SharedRow(this.ptCurrentCell.Y).GetHeight(this.ptCurrentCell.Y)); 20371if (!this.Columns[this.ptCurrentCell.X].Frozen) 20380if ((this.Rows.GetRowState(this.ptCurrentCell.Y) & DataGridViewElementStates.Frozen) == 0) 20400bool isFirstDisplayedColumn = this.FirstDisplayedColumnIndex == this.ptCurrentCell.X; 20401bool isFirstDisplayedRow = this.FirstDisplayedRowIndex == this.ptCurrentCell.Y; 20612if (this.ptCurrentCell.X > -1 && 20716if (this.ptCurrentCell.Y != -1) 20718nextVisibleRowIndex = this.Rows.GetNextRow(this.ptCurrentCell.Y, DataGridViewElementStates.Visible); 20733if (this.ptCurrentCell.X == -1) 20759if (!ScrollIntoView(this.ptCurrentCell.X, lastVisibleRowIndex, true)) 20766int oldEdgeColumnIndex = this.ptCurrentCell.X; 20767int oldEdgeRowIndex = this.ptCurrentCell.Y; 20768if (this.ptCurrentCell.X == -1 || this.ptAnchorCell.X == -1 || 20776success = SetCurrentCellAddressCore(this.ptCurrentCell.X, lastVisibleRowIndex, false, false, false); 20784if (!ScrollIntoView(this.ptCurrentCell.X, lastVisibleRowIndex, true)) 20788if (this.ptCurrentCell.X == -1 || IsRowOutOfBounds(lastVisibleRowIndex)) 20795SetSelectedCellCore(this.ptCurrentCell.X, lastVisibleRowIndex, true); 20796success = SetCurrentCellAddressCore(this.ptCurrentCell.X, lastVisibleRowIndex, true, false, false); 20806if (this.ptCurrentCell.X == -1) 20825if (!ScrollIntoView(this.ptCurrentCell.X, lastVisibleRowIndex, true)) 20829if (this.ptCurrentCell.X == -1 || IsRowOutOfBounds(lastVisibleRowIndex)) 20835SetSelectedCellCore(this.ptCurrentCell.X, lastVisibleRowIndex, true); 20836success = SetCurrentCellAddressCore(this.ptCurrentCell.X, lastVisibleRowIndex, true, false, false); 20848if (this.ptCurrentCell.X == -1) 20872if (!ScrollIntoView(this.ptCurrentCell.X, nextVisibleRowIndex, true)) 20876if (this.ptCurrentCell.X == -1 || IsRowOutOfBounds(nextVisibleRowIndex)) 20884int oldEdgeColumnIndex = this.ptCurrentCell.X; 20885int oldEdgeRowIndex = this.ptCurrentCell.Y; 20897SetSelectedCellCore(this.ptCurrentCell.X, nextVisibleRowIndex, true); 20899success = SetCurrentCellAddressCore(this.ptCurrentCell.X, nextVisibleRowIndex, !this.MultiSelect, false, false); 20908if (this.ptCurrentCell.X == -1) 20932if (!ScrollIntoView(this.ptCurrentCell.X, nextVisibleRowIndex, true /*forCurrentCellChange*/)) 20936if (this.ptCurrentCell.X == -1 || IsRowOutOfBounds(nextVisibleRowIndex)) 20942SetSelectedCellCore(this.ptCurrentCell.X, nextVisibleRowIndex, true); 20943success = SetCurrentCellAddressCore(this.ptCurrentCell.X, 20962if (this.ptCurrentCell.X == -1) 20983if (!ScrollIntoView(this.ptCurrentCell.X, lastVisibleRowIndex, true)) 20987if (this.ptAnchorCell.Y == -1 || this.ptCurrentCell.X == -1 || 20996success = SetCurrentCellAddressCore(this.ptCurrentCell.X, lastVisibleRowIndex, false, false, false); 21004if (!ScrollIntoView(this.ptCurrentCell.X, lastVisibleRowIndex, true)) 21008if (this.ptCurrentCell.X == -1 || IsRowOutOfBounds(lastVisibleRowIndex)) 21013SetSelectedRowCore(this.ptCurrentCell.Y, false); 21015success = SetCurrentCellAddressCore(this.ptCurrentCell.X, lastVisibleRowIndex, true, false, false); 21025if (this.ptCurrentCell.X == -1) 21044if (!ScrollIntoView(this.ptCurrentCell.X, lastVisibleRowIndex, true)) 21048if (this.ptCurrentCell.X == -1 || IsRowOutOfBounds(lastVisibleRowIndex)) 21055success = SetCurrentCellAddressCore(this.ptCurrentCell.X, lastVisibleRowIndex, true, false, false); 21067if (this.ptCurrentCell.X == -1) 21091if (!ScrollIntoView(this.ptCurrentCell.X, nextVisibleRowIndex, true)) 21095if (this.ptCurrentCell.X == -1 || IsRowOutOfBounds(nextVisibleRowIndex)) 21121success = SetCurrentCellAddressCore(this.ptCurrentCell.X, nextVisibleRowIndex, !this.MultiSelect, false, false); 21130if (this.ptCurrentCell.X == -1) 21154if (!ScrollIntoView(this.ptCurrentCell.X, nextVisibleRowIndex, true)) 21158if (this.ptCurrentCell.X == -1 || IsRowOutOfBounds(nextVisibleRowIndex)) 21165success = SetCurrentCellAddressCore(this.ptCurrentCell.X, nextVisibleRowIndex, true, false, false); 21180if (this.ptCurrentCell.X == -1) 21201if (!ScrollIntoView(this.ptCurrentCell.X, lastVisibleRowIndex, true)) 21206if (this.ptAnchorCell.Y == -1 || this.ptCurrentCell.Y == -1 || 21212if ((this.Rows.GetRowState(this.ptCurrentCell.Y) & DataGridViewElementStates.Selected) != 0) 21221int oldEdgeColumnIndex = this.ptCurrentCell.X; 21222int oldEdgeRowIndex = this.ptCurrentCell.Y; 21226success = SetCurrentCellAddressCore(this.ptCurrentCell.X, lastVisibleRowIndex, false, false, false); 21234if (!ScrollIntoView(this.ptCurrentCell.X, lastVisibleRowIndex, true)) 21238if (this.ptCurrentCell.Y == -1 || IsRowOutOfBounds(lastVisibleRowIndex)) 21243if ((this.Rows.GetRowState(this.ptCurrentCell.Y) & DataGridViewElementStates.Selected) != 0) 21245SetSelectedRowCore(this.ptCurrentCell.Y, false); 21250SetSelectedCellCore(this.ptCurrentCell.X, this.ptCurrentCell.Y, false); 21251SetSelectedCellCore(this.ptCurrentCell.X, lastVisibleRowIndex, true); 21253success = SetCurrentCellAddressCore(this.ptCurrentCell.X, lastVisibleRowIndex, true, false, false); 21263if (this.ptCurrentCell.X == -1) 21282if (!ScrollIntoView(this.ptCurrentCell.X, lastVisibleRowIndex, true)) 21286if (this.ptCurrentCell.Y == -1 || IsRowOutOfBounds(lastVisibleRowIndex)) 21291if ((this.Rows.GetRowState(this.ptCurrentCell.Y) & DataGridViewElementStates.Selected) != 0) 21299SetSelectedCellCore(this.ptCurrentCell.X, lastVisibleRowIndex, true); 21301success = SetCurrentCellAddressCore(this.ptCurrentCell.X, lastVisibleRowIndex, true, false, false); 21313if (this.ptCurrentCell.X == -1) 21337if (!ScrollIntoView(this.ptCurrentCell.X, nextVisibleRowIndex, true)) 21341if (this.ptCurrentCell.Y == -1 || IsRowOutOfBounds(nextVisibleRowIndex)) 21346if ((this.Rows.GetRowState(this.ptCurrentCell.Y) & DataGridViewElementStates.Selected) != 0) 21375int oldEdgeColumnIndex = this.ptCurrentCell.X; 21376int oldEdgeRowIndex = this.ptCurrentCell.Y; 21388SetSelectedCellCore(this.ptCurrentCell.X, nextVisibleRowIndex, true); 21391success = SetCurrentCellAddressCore(this.ptCurrentCell.X, nextVisibleRowIndex, !this.MultiSelect, false, false); 21400if (this.ptCurrentCell.X == -1) 21424if (!ScrollIntoView(this.ptCurrentCell.X, nextVisibleRowIndex, true)) 21428if (this.ptCurrentCell.Y == -1 || IsRowOutOfBounds(nextVisibleRowIndex)) 21433if ((this.Rows.GetRowState(this.ptCurrentCell.Y) & DataGridViewElementStates.Selected) != 0) 21441SetSelectedCellCore(this.ptCurrentCell.X, nextVisibleRowIndex, true); 21443success = SetCurrentCellAddressCore(this.ptCurrentCell.X, nextVisibleRowIndex, true, false, false); 21456if (this.ptCurrentCell.X == -1) 21475if (!ScrollIntoView(this.ptCurrentCell.X, lastVisibleRowIndex, true)) 21479if (this.ptCurrentCell.X == -1 || IsRowOutOfBounds(lastVisibleRowIndex)) 21484success = SetCurrentCellAddressCore(this.ptCurrentCell.X, lastVisibleRowIndex, true, false, false); 21493if (this.ptCurrentCell.X == -1) 21517if (!ScrollIntoView(this.ptCurrentCell.X, nextVisibleRowIndex, true)) 21521if (this.ptCurrentCell.X == -1 || IsRowOutOfBounds(nextVisibleRowIndex)) 21526success = SetCurrentCellAddressCore(this.ptCurrentCell.X, nextVisibleRowIndex, true, false, false); 21584int oldEdgeColumnIndex = this.ptCurrentCell.X; 21585int oldEdgeRowIndex = this.ptCurrentCell.Y; 21628if (this.ptCurrentCell.Y > -1 && 21629(this.Rows.GetRowState(this.ptCurrentCell.Y) & DataGridViewElementStates.Selected) != 0) 21632SelectRowRange(this.ptCurrentCell.Y, lastVisibleRowIndex, true); 21636int oldEdgeColumnIndex = this.ptCurrentCell.X; 21637int oldEdgeRowIndex = this.ptCurrentCell.Y; 21644if (this.ptCurrentCell.Y > -1 && 21645(this.Rows.GetRowState(this.ptCurrentCell.Y) & DataGridViewElementStates.Selected) != 0) 21660if (this.ptCurrentCell.Y > -1 && 21661(this.Rows.GetRowState(this.ptCurrentCell.Y) & DataGridViewElementStates.Selected) != 0) 21695if (this.MultiSelect && this.ptCurrentCell.X >= 0) 21731if (this.ptCurrentCell.X >= 0 && this.Columns[this.ptCurrentCell.X].Selected) 21746if (this.MultiSelect && this.ptCurrentCell.X >= 0) 21748int oldEdgeColumnIndex = this.ptCurrentCell.X; 21749int oldEdgeRowIndex = this.ptCurrentCell.Y; 21776if (this.ptCurrentCell.X >= 0 && this.Columns[this.ptCurrentCell.X].Selected) 21810if (this.MultiSelect && this.ptCurrentCell.Y >= 0) 21867if (this.ptCurrentCell.X != -1) 21903int columnIndex = this.ptCurrentCell.X; 21904int rowIndex = this.ptCurrentCell.Y; 21951if (this.ptCurrentCell.X != -1 && 21955Debug.Assert(this.ptCurrentCell.Y != -1); 21958(IsSharedCellReadOnly(this.CurrentCellInternal, this.ptCurrentCell.Y) || !ColumnEditable(this.ptCurrentCell.X))); 21959if (ColumnEditable(this.ptCurrentCell.X) && 21960!IsSharedCellReadOnly(this.CurrentCellInternal, this.ptCurrentCell.Y) && 21964bool success = ScrollIntoView(this.ptCurrentCell.X, this.ptCurrentCell.Y, false); 21984if (this.ptCurrentCell.X != -1 && AccessibilityImprovements.Level2) 21986DataGridViewColumn dataGridViewColumn = Columns[this.ptCurrentCell.X]; 22038int oldEdgeColumnIndex = this.ptCurrentCell.X; 22039int oldEdgeRowIndex = this.ptCurrentCell.Y; 22082if (this.ptCurrentCell.Y > -1 && 22083(this.Rows.GetRowState(this.ptCurrentCell.Y) & DataGridViewElementStates.Selected) != 0) 22090int oldEdgeColumnIndex = this.ptCurrentCell.X; 22091int oldEdgeRowIndex = this.ptCurrentCell.Y; 22098if (this.ptCurrentCell.Y > -1 && 22099(this.Rows.GetRowState(this.ptCurrentCell.Y) & DataGridViewElementStates.Selected) != 0) 22114if (this.ptCurrentCell.Y > -1 && 22115(this.Rows.GetRowState(this.ptCurrentCell.Y) & DataGridViewElementStates.Selected) != 0) 22149if (this.MultiSelect && this.ptCurrentCell.X >= 0) 22189if (this.ptCurrentCell.X >= 0 && this.Columns[this.ptCurrentCell.X].Selected) 22204if (this.MultiSelect && this.ptCurrentCell.X >= 0) 22206int oldEdgeColumnIndex = this.ptCurrentCell.X; 22207int oldEdgeRowIndex = this.ptCurrentCell.Y; 22234if (this.ptCurrentCell.X >= 0 && this.Columns[this.ptCurrentCell.X].Selected) 22308if (this.ptCurrentCell.X != -1) 22314ColumnEditable(this.ptCurrentCell.X) && 22315!IsSharedCellReadOnly(dataGridViewCell, this.ptCurrentCell.Y) && 22333bool success = ScrollIntoView(this.ptCurrentCell.X, this.ptCurrentCell.Y, false); 22454if (AccessibilityImprovements.Level2 && (keyData & Keys.Alt) == Keys.Alt && this.AllowUserToResizeColumns && this.ptCurrentCell.X != -1) 22458DataGridViewColumn dataGridViewColumn = Columns[this.ptCurrentCell.X]; 22462BeginKeyboardColumnResize(this.ptCurrentCell.X); 22515if (this.ptCurrentCell.X != -1) 22517dataGridViewColumn = this.Columns.GetPreviousColumn(this.Columns[this.ptCurrentCell.X], 22541if (this.ptCurrentCell.X == -1) 22560if (!ScrollIntoView(previousVisibleColumnIndex, this.ptCurrentCell.Y, true)) 22564if (this.ptCurrentCell.Y == -1 || IsColumnOutOfBounds(previousVisibleColumnIndex)) 22572int oldEdgeColumnIndex = this.ptCurrentCell.X; 22573int oldEdgeRowIndex = this.ptCurrentCell.Y; 22584SetSelectedCellCore(previousVisibleColumnIndex, this.ptCurrentCell.Y, true); 22586success = SetCurrentCellAddressCore(previousVisibleColumnIndex, this.ptCurrentCell.Y, !this.MultiSelect, false, false); 22592if (this.ptCurrentCell.X == -1) 22611if (!ScrollIntoView(previousVisibleColumnIndex, this.ptCurrentCell.Y, true)) 22615if (this.ptCurrentCell.Y == -1 || IsColumnOutOfBounds(previousVisibleColumnIndex)) 22620SetSelectedCellCore(previousVisibleColumnIndex, this.ptCurrentCell.Y, true); 22621success = SetCurrentCellAddressCore(previousVisibleColumnIndex, this.ptCurrentCell.Y, true, false, false); 22637if (this.ptCurrentCell.X == -1) 22656if (!ScrollIntoView(previousVisibleColumnIndex, this.ptCurrentCell.Y, true)) 22660if (this.ptCurrentCell.Y == -1 || IsColumnOutOfBounds(previousVisibleColumnIndex)) 22684success = SetCurrentCellAddressCore(previousVisibleColumnIndex, this.ptCurrentCell.Y, !this.MultiSelect, false, false); 22690if (this.ptCurrentCell.X == -1) 22709if (!ScrollIntoView(previousVisibleColumnIndex, this.ptCurrentCell.Y, true)) 22713if (this.ptCurrentCell.Y == -1 || IsColumnOutOfBounds(previousVisibleColumnIndex)) 22719success = SetCurrentCellAddressCore(previousVisibleColumnIndex, this.ptCurrentCell.Y, true, false, false); 22735if (this.ptCurrentCell.X == -1) 22754if (!ScrollIntoView(previousVisibleColumnIndex, this.ptCurrentCell.Y, true)) 22758if (this.ptCurrentCell.X == -1 || IsColumnOutOfBounds(previousVisibleColumnIndex)) 22762if (this.Columns[this.ptCurrentCell.X].Selected) 22787int oldEdgeColumnIndex = this.ptCurrentCell.X; 22788int oldEdgeRowIndex = this.ptCurrentCell.Y; 22799SetSelectedCellCore(previousVisibleColumnIndex, this.ptCurrentCell.Y, true); 22802success = SetCurrentCellAddressCore(previousVisibleColumnIndex, this.ptCurrentCell.Y, !this.MultiSelect, false, false); 22808if (this.ptCurrentCell.X == -1) 22827if (!ScrollIntoView(previousVisibleColumnIndex, this.ptCurrentCell.Y, true)) 22831if (this.ptCurrentCell.X == -1 || IsColumnOutOfBounds(previousVisibleColumnIndex)) 22835if (this.Columns[this.ptCurrentCell.X].Selected) 22843SetSelectedCellCore(previousVisibleColumnIndex, this.ptCurrentCell.Y, true); 22845success = SetCurrentCellAddressCore(previousVisibleColumnIndex, this.ptCurrentCell.Y, true, false, false); 22859if (this.ptCurrentCell.X == -1) 22878if (!ScrollIntoView(previousVisibleColumnIndex, this.ptCurrentCell.Y, true)) 22882if (this.ptCurrentCell.Y == -1 || IsColumnOutOfBounds(previousVisibleColumnIndex)) 22886success = SetCurrentCellAddressCore(previousVisibleColumnIndex, this.ptCurrentCell.Y, true, false, false); 22915if (this.ptCurrentCell.X == -1) 22932if (!ScrollIntoView(firstVisibleColumnIndex, this.ptCurrentCell.Y, true)) 22939int oldEdgeColumnIndex = this.ptCurrentCell.X; 22940int oldEdgeRowIndex = this.ptCurrentCell.Y; 22941if (this.ptAnchorCell.X == -1 || this.ptCurrentCell.X == -1 || 22948success = SetCurrentCellAddressCore(firstVisibleColumnIndex, this.ptCurrentCell.Y, false, false, false); 22953if (!ScrollIntoView(firstVisibleColumnIndex, this.ptCurrentCell.Y, true)) 22957if (this.ptCurrentCell.Y == -1 || IsColumnOutOfBounds(firstVisibleColumnIndex)) 22963SetSelectedCellCore(firstVisibleColumnIndex, this.ptCurrentCell.Y, true); 22964success = SetCurrentCellAddressCore(firstVisibleColumnIndex, this.ptCurrentCell.Y, true, false, false); 22971if (this.ptCurrentCell.X == -1) 22986if (!ScrollIntoView(firstVisibleColumnIndex, this.ptCurrentCell.Y, true)) 22990if (this.ptCurrentCell.Y == -1 || IsColumnOutOfBounds(firstVisibleColumnIndex)) 22995SetSelectedCellCore(firstVisibleColumnIndex, this.ptCurrentCell.Y, true); 22996success = SetCurrentCellAddressCore(firstVisibleColumnIndex, this.ptCurrentCell.Y, true, false, false); 23005if (this.ptCurrentCell.X == -1) 23022if (!ScrollIntoView(firstVisibleColumnIndex, this.ptCurrentCell.Y, true)) 23026if (this.ptAnchorCell.X == -1 || this.ptCurrentCell.Y == -1 || 23034success = SetCurrentCellAddressCore(firstVisibleColumnIndex, this.ptCurrentCell.Y, false, false, false); 23039if (!ScrollIntoView(firstVisibleColumnIndex, this.ptCurrentCell.Y, true)) 23043if (this.ptCurrentCell.X == -1 || IsColumnOutOfBounds(firstVisibleColumnIndex)) 23047SetSelectedColumnCore(this.ptCurrentCell.X, false); 23049success = SetCurrentCellAddressCore(firstVisibleColumnIndex, this.ptCurrentCell.Y, true, false, false); 23056if (this.ptCurrentCell.X == -1) 23071if (!ScrollIntoView(firstVisibleColumnIndex, this.ptCurrentCell.Y, true)) 23075if (this.ptCurrentCell.Y == -1 || IsColumnOutOfBounds(firstVisibleColumnIndex)) 23081success = SetCurrentCellAddressCore(firstVisibleColumnIndex, this.ptCurrentCell.Y, true, false, false); 23090if (this.ptCurrentCell.X == -1) 23107if (!ScrollIntoView(firstVisibleColumnIndex, this.ptCurrentCell.Y, true)) 23111if (this.ptAnchorCell.X == -1 || this.ptCurrentCell.X == -1 || 23117if (this.Columns[this.ptCurrentCell.X].Selected) 23126int oldEdgeColumnIndex = this.ptCurrentCell.X; 23127int oldEdgeRowIndex = this.ptCurrentCell.Y; 23131success = SetCurrentCellAddressCore(firstVisibleColumnIndex, this.ptCurrentCell.Y, false, false, false); 23136if (!ScrollIntoView(firstVisibleColumnIndex, this.ptCurrentCell.Y, true)) 23140if (this.ptCurrentCell.X == -1 || 23145if (this.Columns[this.ptCurrentCell.X].Selected) 23147SetSelectedColumnCore(this.ptCurrentCell.X, false); 23152SetSelectedCellCore(this.ptCurrentCell.X, this.ptCurrentCell.Y, false); 23153SetSelectedCellCore(firstVisibleColumnIndex, this.ptCurrentCell.Y, true); 23155success = SetCurrentCellAddressCore(firstVisibleColumnIndex, this.ptCurrentCell.Y, true, false, false); 23162if (this.ptCurrentCell.X == -1) 23177if (!ScrollIntoView(firstVisibleColumnIndex, this.ptCurrentCell.Y, true)) 23181if (this.ptCurrentCell.X == -1 || IsColumnOutOfBounds(firstVisibleColumnIndex)) 23185if (this.Columns[this.ptCurrentCell.X].Selected) 23193SetSelectedCellCore(firstVisibleColumnIndex, this.ptCurrentCell.Y, true); 23195success = SetCurrentCellAddressCore(firstVisibleColumnIndex, this.ptCurrentCell.Y, true, false, false); 23202if (this.ptCurrentCell.X == -1) 23217if (!ScrollIntoView(firstVisibleColumnIndex, this.ptCurrentCell.Y, true)) 23221if (this.ptCurrentCell.Y == -1 || IsColumnOutOfBounds(firstVisibleColumnIndex)) 23225success = SetCurrentCellAddressCore(firstVisibleColumnIndex, this.ptCurrentCell.Y, true, false, false); 23252if (this.ptCurrentCell.Y == -1) 23262nextScreenVisibleRowIndex = this.ptCurrentCell.Y; 23271if (!ScrollIntoView(this.ptCurrentCell.X == -1 ? firstVisibleColumnIndex : this.ptCurrentCell.X, 23277this.ptCurrentCell.Y, 23306if (this.ptCurrentCell.X == -1) 23341if (!ScrollIntoView(this.ptCurrentCell.X, nextScreenVisibleRowIndex, true)) 23345if (this.ptCurrentCell.X == -1 || IsRowOutOfBounds(nextScreenVisibleRowIndex)) 23352int oldEdgeColumnIndex = this.ptCurrentCell.X; 23353int oldEdgeRowIndex = this.ptCurrentCell.Y; 23364SetSelectedCellCore(this.ptCurrentCell.X, nextScreenVisibleRowIndex, true); 23366success = SetCurrentCellAddressCore(this.ptCurrentCell.X, nextScreenVisibleRowIndex, false, false, false); 23371if (!ScrollIntoView(this.ptCurrentCell.X, nextScreenVisibleRowIndex, true)) 23375if (this.ptCurrentCell.X == -1 || IsRowOutOfBounds(nextScreenVisibleRowIndex)) 23400success = SetCurrentCellAddressCore(this.ptCurrentCell.X, nextScreenVisibleRowIndex, false, false, false); 23405if (!ScrollIntoView(this.ptCurrentCell.X, nextScreenVisibleRowIndex, true)) 23409if (this.ptCurrentCell.X == -1 || IsRowOutOfBounds(nextScreenVisibleRowIndex)) 23420if ((this.Rows.GetRowState(this.ptCurrentCell.Y) & DataGridViewElementStates.Selected) != 0) 23434int oldEdgeColumnIndex = this.ptCurrentCell.X; 23435int oldEdgeRowIndex = this.ptCurrentCell.Y; 23442if ((this.Rows.GetRowState(this.ptCurrentCell.Y) & DataGridViewElementStates.Selected) != 0) 23450SetSelectedCellCore(this.ptCurrentCell.X, nextScreenVisibleRowIndex, true); 23453success = SetCurrentCellAddressCore(this.ptCurrentCell.X, nextScreenVisibleRowIndex, !this.MultiSelect, false, false); 23458if (!ScrollIntoView(this.ptCurrentCell.X, nextScreenVisibleRowIndex, true)) 23462if (this.ptCurrentCell.X == -1 || IsRowOutOfBounds(nextScreenVisibleRowIndex)) 23466success = SetCurrentCellAddressCore(this.ptCurrentCell.X, nextScreenVisibleRowIndex, true, false, false); 23492if (this.ptCurrentCell.Y == -1) 23502previousScreenVisibleRowIndex = this.ptCurrentCell.Y; 23535!ScrollIntoView(this.ptCurrentCell.X == -1 ? firstVisibleColumnIndex : this.ptCurrentCell.X, 23548if (this.ptCurrentCell.X == -1) 23580if (!ScrollIntoView(this.ptCurrentCell.X, previousScreenVisibleRowIndex, true)) 23584if (this.ptCurrentCell.X == -1 || IsRowOutOfBounds(previousScreenVisibleRowIndex)) 23591int oldEdgeColumnIndex = this.ptCurrentCell.X; 23592int oldEdgeRowIndex = this.ptCurrentCell.Y; 23603SetSelectedCellCore(this.ptCurrentCell.X, previousScreenVisibleRowIndex, true); 23605success = SetCurrentCellAddressCore(this.ptCurrentCell.X, previousScreenVisibleRowIndex, false, false, false); 23610if (!ScrollIntoView(this.ptCurrentCell.X, previousScreenVisibleRowIndex, true)) 23614if (this.ptCurrentCell.X == -1 || IsRowOutOfBounds(previousScreenVisibleRowIndex)) 23639success = SetCurrentCellAddressCore(this.ptCurrentCell.X, previousScreenVisibleRowIndex, false, false, false); 23644if (!ScrollIntoView(this.ptCurrentCell.X, previousScreenVisibleRowIndex, true)) 23648if (this.ptCurrentCell.X == -1 || IsRowOutOfBounds(previousScreenVisibleRowIndex)) 23659if ((this.Rows.GetRowState(this.ptCurrentCell.Y) & DataGridViewElementStates.Selected) != 0) 23673int oldEdgeColumnIndex = this.ptCurrentCell.X; 23674int oldEdgeRowIndex = this.ptCurrentCell.Y; 23681if ((this.Rows.GetRowState(this.ptCurrentCell.Y) & DataGridViewElementStates.Selected) != 0) 23689SetSelectedCellCore(this.ptCurrentCell.X, previousScreenVisibleRowIndex, true); 23692success = SetCurrentCellAddressCore(this.ptCurrentCell.X, previousScreenVisibleRowIndex, !this.MultiSelect, false, false); 23697if (!ScrollIntoView(this.ptCurrentCell.X, previousScreenVisibleRowIndex, true)) 23701if (this.ptCurrentCell.X == -1 || IsRowOutOfBounds(previousScreenVisibleRowIndex)) 23705success = SetCurrentCellAddressCore(this.ptCurrentCell.X, previousScreenVisibleRowIndex, true, false, false); 23754if (this.ptCurrentCell.X != -1) 23756dataGridViewColumn = this.Columns.GetNextColumn(this.Columns[this.ptCurrentCell.X], 23780if (this.ptCurrentCell.X == -1) 23799if (!ScrollIntoView(nextVisibleColumnIndex, this.ptCurrentCell.Y, true)) 23803if (this.ptCurrentCell.Y == -1 || IsColumnOutOfBounds(nextVisibleColumnIndex)) 23810int oldEdgeColumnIndex = this.ptCurrentCell.X; 23811int oldEdgeRowIndex = this.ptCurrentCell.Y; 23822SetSelectedCellCore(nextVisibleColumnIndex, this.ptCurrentCell.Y, true); 23824success = SetCurrentCellAddressCore(nextVisibleColumnIndex, this.ptCurrentCell.Y, !this.MultiSelect, false, false); 23830if (this.ptCurrentCell.X == -1) 23849if (!ScrollIntoView(nextVisibleColumnIndex, this.ptCurrentCell.Y, true)) 23853if (this.ptCurrentCell.Y == -1 || IsColumnOutOfBounds(nextVisibleColumnIndex)) 23858SetSelectedCellCore(nextVisibleColumnIndex, this.ptCurrentCell.Y, true); 23859success = SetCurrentCellAddressCore(nextVisibleColumnIndex, this.ptCurrentCell.Y, true, false, false); 23875if (this.ptCurrentCell.X == -1) 23894if (!ScrollIntoView(nextVisibleColumnIndex, this.ptCurrentCell.Y, true)) 23898if (this.ptCurrentCell.Y == -1 || IsColumnOutOfBounds(nextVisibleColumnIndex)) 23922success = SetCurrentCellAddressCore(nextVisibleColumnIndex, this.ptCurrentCell.Y, !this.MultiSelect, false, false); 23928if (this.ptCurrentCell.X == -1) 23947if (!ScrollIntoView(nextVisibleColumnIndex, this.ptCurrentCell.Y, true)) 23951if (this.ptCurrentCell.Y == -1 || IsColumnOutOfBounds(nextVisibleColumnIndex)) 23957success = SetCurrentCellAddressCore(nextVisibleColumnIndex, this.ptCurrentCell.Y, true, false, false); 23973if (this.ptCurrentCell.X == -1) 23992if (!ScrollIntoView(nextVisibleColumnIndex, this.ptCurrentCell.Y, true)) 23996if (this.ptCurrentCell.Y == -1 || IsColumnOutOfBounds(nextVisibleColumnIndex)) 24000if (this.Columns[this.ptCurrentCell.X].Selected) 24032int oldEdgeColumnIndex = this.ptCurrentCell.X; 24033int oldEdgeRowIndex = this.ptCurrentCell.Y; 24040SetSelectedCellCore(nextVisibleColumnIndex, this.ptCurrentCell.Y, true); 24043success = SetCurrentCellAddressCore(nextVisibleColumnIndex, this.ptCurrentCell.Y, !this.MultiSelect, false, false); 24049if (this.ptCurrentCell.X == -1) 24068if (!ScrollIntoView(nextVisibleColumnIndex, this.ptCurrentCell.Y, true)) 24072if (this.ptCurrentCell.X == -1 || IsColumnOutOfBounds(nextVisibleColumnIndex)) 24076if (this.Columns[this.ptCurrentCell.X].Selected) 24084SetSelectedCellCore(nextVisibleColumnIndex, this.ptCurrentCell.Y, true); 24086success = SetCurrentCellAddressCore(nextVisibleColumnIndex, this.ptCurrentCell.Y, true, false, false); 24100if (this.ptCurrentCell.X == -1) 24119if (!ScrollIntoView(nextVisibleColumnIndex, this.ptCurrentCell.Y, true)) 24123if (this.ptCurrentCell.Y == -1 || IsColumnOutOfBounds(nextVisibleColumnIndex)) 24127success = SetCurrentCellAddressCore(nextVisibleColumnIndex, this.ptCurrentCell.Y, true, false, false); 24156if (this.ptCurrentCell.X == -1) 24171if (!ScrollIntoView(lastVisibleColumnIndex, this.ptCurrentCell.Y, true)) 24175if (this.ptCurrentCell.Y == -1 || IsColumnOutOfBounds(lastVisibleColumnIndex)) 24186int oldEdgeColumnIndex = this.ptCurrentCell.X; 24187int oldEdgeRowIndex = this.ptCurrentCell.Y; 24190success = SetCurrentCellAddressCore(lastVisibleColumnIndex, this.ptCurrentCell.Y, false, false, false); 24196SetSelectedCellCore(lastVisibleColumnIndex, this.ptCurrentCell.Y, true); 24197success = SetCurrentCellAddressCore(lastVisibleColumnIndex, this.ptCurrentCell.Y, true, false, false); 24204if (this.ptCurrentCell.X == -1) 24219if (!ScrollIntoView(lastVisibleColumnIndex, this.ptCurrentCell.Y, true)) 24223if (this.ptCurrentCell.Y == -1 || IsColumnOutOfBounds(lastVisibleColumnIndex)) 24228SetSelectedCellCore(lastVisibleColumnIndex, this.ptCurrentCell.Y, true); 24229success = SetCurrentCellAddressCore(lastVisibleColumnIndex, this.ptCurrentCell.Y, true, false, false); 24238if (this.ptCurrentCell.X == -1) 24253if (!ScrollIntoView(lastVisibleColumnIndex, this.ptCurrentCell.Y, true)) 24257if (this.ptCurrentCell.Y == -1 || IsColumnOutOfBounds(lastVisibleColumnIndex)) 24270success = SetCurrentCellAddressCore(lastVisibleColumnIndex, this.ptCurrentCell.Y, false, false, false); 24275SetSelectedColumnCore(this.ptCurrentCell.X, false); 24277success = SetCurrentCellAddressCore(lastVisibleColumnIndex, this.ptCurrentCell.Y, true, false, false); 24284if (this.ptCurrentCell.X == -1) 24299if (!ScrollIntoView(lastVisibleColumnIndex, this.ptCurrentCell.Y, true)) 24303if (this.ptCurrentCell.Y == -1 || IsColumnOutOfBounds(lastVisibleColumnIndex)) 24309success = SetCurrentCellAddressCore(lastVisibleColumnIndex, this.ptCurrentCell.Y, true, false, false); 24318if (this.ptCurrentCell.X == -1) 24333if (!ScrollIntoView(lastVisibleColumnIndex, this.ptCurrentCell.Y, true)) 24337if (this.ptCurrentCell.Y == -1 || IsColumnOutOfBounds(lastVisibleColumnIndex)) 24348if (this.Columns[this.ptCurrentCell.X].Selected) 24357int oldEdgeColumnIndex = this.ptCurrentCell.X; 24358int oldEdgeRowIndex = this.ptCurrentCell.Y; 24362success = SetCurrentCellAddressCore(lastVisibleColumnIndex, this.ptCurrentCell.Y, false, false, false); 24367if (this.Columns[this.ptCurrentCell.X].Selected) 24369SetSelectedColumnCore(this.ptCurrentCell.X, false); 24374SetSelectedCellCore(this.ptCurrentCell.X, this.ptCurrentCell.Y, false); 24375SetSelectedCellCore(lastVisibleColumnIndex, this.ptCurrentCell.Y, true); 24377success = SetCurrentCellAddressCore(lastVisibleColumnIndex, this.ptCurrentCell.Y, true, false, false); 24384if (this.ptCurrentCell.X == -1) 24399if (!ScrollIntoView(lastVisibleColumnIndex, this.ptCurrentCell.Y, true)) 24403if (this.ptCurrentCell.Y == -1 || IsColumnOutOfBounds(lastVisibleColumnIndex)) 24407if (this.Columns[this.ptCurrentCell.X].Selected) 24415SetSelectedCellCore(lastVisibleColumnIndex, this.ptCurrentCell.Y, true); 24417success = SetCurrentCellAddressCore(lastVisibleColumnIndex, this.ptCurrentCell.Y, true, false, false); 24424if (this.ptCurrentCell.X == -1) 24439if (!ScrollIntoView(lastVisibleColumnIndex, this.ptCurrentCell.Y, true)) 24443if (this.ptCurrentCell.Y == -1 || IsColumnOutOfBounds(lastVisibleColumnIndex)) 24447success = SetCurrentCellAddressCore(lastVisibleColumnIndex, this.ptCurrentCell.Y, true, false, false); 24467this.ptCurrentCell.X != -1) 24485if (this.selectedBandIndexes[bandIndex] != this.ptCurrentCell.X) 24496if (!this.Columns[this.ptCurrentCell.X].Selected) 24498Debug.Assert(!this.selectedBandIndexes.Contains(this.ptCurrentCell.X)); 24499SetSelectedColumnCore(this.ptCurrentCell.X, true); 24510if (this.selectedBandIndexes[bandIndex] != this.ptCurrentCell.Y) 24521if ((this.Rows.GetRowState(this.ptCurrentCell.Y) & DataGridViewElementStates.Selected) == 0) 24523Debug.Assert(!this.selectedBandIndexes.Contains(this.ptCurrentCell.Y)); 24524SetSelectedRowCore(this.ptCurrentCell.Y, true); 24751if (this.ptCurrentCell.Y != -1) 24753previousVisibleRowIndex = this.Rows.GetPreviousRow(this.ptCurrentCell.Y, DataGridViewElementStates.Visible); 24767if (this.ptCurrentCell.X == -1) 24787if (!ScrollIntoView(this.ptCurrentCell.X, firstVisibleRowIndex, true)) 24791if (this.ptAnchorCell.X == -1 || this.ptCurrentCell.X == -1 || 24799int oldEdgeColumnIndex = this.ptCurrentCell.X; 24800int oldEdgeRowIndex = this.ptCurrentCell.Y; 24803success = SetCurrentCellAddressCore(this.ptCurrentCell.X, firstVisibleRowIndex, false, false, false); 24808if (!ScrollIntoView(this.ptCurrentCell.X, firstVisibleRowIndex, true)) 24812if (this.ptCurrentCell.X == -1 || IsRowOutOfBounds(firstVisibleRowIndex)) 24818SetSelectedCellCore(this.ptCurrentCell.X, firstVisibleRowIndex, true); 24819success = SetCurrentCellAddressCore(this.ptCurrentCell.X, firstVisibleRowIndex, true, false, false); 24826if (this.ptCurrentCell.X == -1) 24841if (!ScrollIntoView(this.ptCurrentCell.X, firstVisibleRowIndex, true)) 24845if (this.ptCurrentCell.X == -1 || IsRowOutOfBounds(firstVisibleRowIndex)) 24850SetSelectedCellCore(this.ptCurrentCell.X, firstVisibleRowIndex, true); 24851success = SetCurrentCellAddressCore(this.ptCurrentCell.X, firstVisibleRowIndex, true, false, false); 24860if (this.ptCurrentCell.X == -1) 24879if (!ScrollIntoView(this.ptCurrentCell.X, previousVisibleRowIndex, true)) 24883if (this.ptCurrentCell.X == -1 || IsRowOutOfBounds(previousVisibleRowIndex)) 24895int oldEdgeColumnIndex = this.ptCurrentCell.X; 24896int oldEdgeRowIndex = this.ptCurrentCell.Y; 24903SetSelectedCellCore(this.ptCurrentCell.X, previousVisibleRowIndex, true); 24905success = SetCurrentCellAddressCore(this.ptCurrentCell.X, previousVisibleRowIndex, !this.MultiSelect, false, false); 24911if (this.ptCurrentCell.X == -1) 24930if (!ScrollIntoView(this.ptCurrentCell.X, previousVisibleRowIndex, true)) 24934if (this.ptCurrentCell.X == -1 || IsRowOutOfBounds(previousVisibleRowIndex)) 24939SetSelectedCellCore(this.ptCurrentCell.X, previousVisibleRowIndex, true); 24940success = SetCurrentCellAddressCore(this.ptCurrentCell.X, previousVisibleRowIndex, true, false, false); 24952if (this.ptCurrentCell.X == -1) 24969if (!ScrollIntoView(this.ptCurrentCell.X, firstVisibleRowIndex, true)) 24973if (this.ptAnchorCell.X == -1 || this.ptCurrentCell.X == -1 || 24981success = SetCurrentCellAddressCore(this.ptCurrentCell.X, firstVisibleRowIndex, false, false, false); 24986if (!ScrollIntoView(this.ptCurrentCell.X, firstVisibleRowIndex, true)) 24990if (this.ptCurrentCell.X == -1 || IsRowOutOfBounds(firstVisibleRowIndex)) 24994SetSelectedRowCore(this.ptCurrentCell.Y, false); 24996success = SetCurrentCellAddressCore(this.ptCurrentCell.X, firstVisibleRowIndex, true, false, false); 25003if (this.ptCurrentCell.X == -1) 25018if (!ScrollIntoView(this.ptCurrentCell.X, firstVisibleRowIndex, true)) 25022if (this.ptCurrentCell.X == -1 || IsRowOutOfBounds(firstVisibleRowIndex)) 25028success = SetCurrentCellAddressCore(this.ptCurrentCell.X, firstVisibleRowIndex, true, false, false); 25037if (this.ptCurrentCell.X == -1) 25056if (!ScrollIntoView(this.ptCurrentCell.X, previousVisibleRowIndex, true)) 25060if (this.ptCurrentCell.X == -1 || IsRowOutOfBounds(previousVisibleRowIndex)) 25084success = SetCurrentCellAddressCore(this.ptCurrentCell.X, previousVisibleRowIndex, !this.MultiSelect, false, false); 25090if (this.ptCurrentCell.X == -1) 25109if (!ScrollIntoView(this.ptCurrentCell.X, previousVisibleRowIndex, true)) 25113if (this.ptCurrentCell.X == -1 || IsRowOutOfBounds(previousVisibleRowIndex)) 25119success = SetCurrentCellAddressCore(this.ptCurrentCell.X, previousVisibleRowIndex, true, false, false); 25131if (this.ptCurrentCell.X == -1) 25148if (!ScrollIntoView(this.ptCurrentCell.X, firstVisibleRowIndex, true)) 25152if (this.ptAnchorCell.X == -1 || this.ptCurrentCell.X == -1 || 25158if ((this.Rows.GetRowState(this.ptCurrentCell.Y) & DataGridViewElementStates.Selected) != 0) 25167int oldEdgeColumnIndex = this.ptCurrentCell.X; 25168int oldEdgeRowIndex = this.ptCurrentCell.Y; 25172success = SetCurrentCellAddressCore(this.ptCurrentCell.X, firstVisibleRowIndex, false, false, false); 25177if (!ScrollIntoView(this.ptCurrentCell.X, firstVisibleRowIndex, true)) 25181if (this.ptCurrentCell.X == -1 || IsRowOutOfBounds(firstVisibleRowIndex)) 25185if ((this.Rows.GetRowState(this.ptCurrentCell.Y) & DataGridViewElementStates.Selected) != 0) 25187SetSelectedRowCore(this.ptCurrentCell.Y, false); 25192SetSelectedCellCore(this.ptCurrentCell.X, this.ptCurrentCell.Y, false); 25193SetSelectedCellCore(this.ptCurrentCell.X, firstVisibleRowIndex, true); 25195success = SetCurrentCellAddressCore(this.ptCurrentCell.X, firstVisibleRowIndex, true, false, false); 25202if (this.ptCurrentCell.X == -1) 25217if (!ScrollIntoView(this.ptCurrentCell.X, firstVisibleRowIndex, true)) 25221if (this.ptCurrentCell.X == -1 || IsRowOutOfBounds(firstVisibleRowIndex)) 25225if ((this.Rows.GetRowState(this.ptCurrentCell.Y) & DataGridViewElementStates.Selected) != 0) 25233SetSelectedCellCore(this.ptCurrentCell.X, firstVisibleRowIndex, true); 25235success = SetCurrentCellAddressCore(this.ptCurrentCell.X, firstVisibleRowIndex, true, false, false); 25244if (this.ptCurrentCell.X == -1) 25263if (!ScrollIntoView(this.ptCurrentCell.X, previousVisibleRowIndex, true)) 25267if (this.ptCurrentCell.X == -1 || IsRowOutOfBounds(previousVisibleRowIndex)) 25271if ((this.Rows.GetRowState(this.ptCurrentCell.Y) & DataGridViewElementStates.Selected) != 0) 25296int oldEdgeColumnIndex = this.ptCurrentCell.X; 25297int oldEdgeRowIndex = this.ptCurrentCell.Y; 25308SetSelectedCellCore(this.ptCurrentCell.X, previousVisibleRowIndex, true); 25311success = SetCurrentCellAddressCore(this.ptCurrentCell.X, previousVisibleRowIndex, !this.MultiSelect, false, false); 25317if (this.ptCurrentCell.X == -1) 25336if (!ScrollIntoView(this.ptCurrentCell.X, previousVisibleRowIndex, true)) 25340if (this.ptCurrentCell.X == -1 || IsRowOutOfBounds(previousVisibleRowIndex)) 25344if ((this.Rows.GetRowState(this.ptCurrentCell.Y) & DataGridViewElementStates.Selected) != 0) 25352SetSelectedCellCore(this.ptCurrentCell.X, previousVisibleRowIndex, true); 25354success = SetCurrentCellAddressCore(this.ptCurrentCell.X, previousVisibleRowIndex, true, false, false); 25364if (this.ptCurrentCell.X == -1) 25379if (!ScrollIntoView(this.ptCurrentCell.X, firstVisibleRowIndex, true)) 25383if (this.ptCurrentCell.X == -1 || IsRowOutOfBounds(firstVisibleRowIndex)) 25387success = SetCurrentCellAddressCore(this.ptCurrentCell.X, firstVisibleRowIndex, true, false, false); 25393if (this.ptCurrentCell.X == -1) 25412if (!ScrollIntoView(this.ptCurrentCell.X, previousVisibleRowIndex, true)) 25416if (this.ptCurrentCell.X == -1 || IsRowOutOfBounds(previousVisibleRowIndex)) 25420success = SetCurrentCellAddressCore(this.ptCurrentCell.X, previousVisibleRowIndex, true, false, false); 25440if (this.ptCurrentCell.X != -1 && !this.IsCurrentCellInEditMode && ColumnEditable(this.ptCurrentCell.X)) 25445if (!IsSharedCellReadOnly(dataGridViewCell, this.ptCurrentCell.Y) && 25449bool success = ScrollIntoView(this.ptCurrentCell.X, this.ptCurrentCell.Y, false); 25463object nullValue = dataGridViewCurrentCell.GetInheritedStyle(null, this.ptCurrentCell.Y, false).NullValue; 25481InvalidateCellPrivate(this.ptCurrentCell.X, this.ptCurrentCell.Y); 25516DataGridViewCellParsingEventArgs dgvcpe = OnCellParsing(this.ptCurrentCell.Y, 25517this.ptCurrentCell.X, 25528dataGridViewCurrentCell = this.Rows[this.ptCurrentCell.Y].Cells[this.ptCurrentCell.X]; // unsharing the row before pushing the new value 25530return dataGridViewCurrentCell.SetValueInternal(this.ptCurrentCell.Y, dgvcpe.Value); 25549dataGridViewCurrentCell = this.Rows[this.ptCurrentCell.Y].Cells[this.ptCurrentCell.X]; // unsharing the row before pushing the new value 25551return dataGridViewCurrentCell.SetValueInternal(this.ptCurrentCell.Y, val); 25637if (this.ptCurrentCell.X != -1 && this.IsCurrentCellInEditMode) 25639Debug.Assert(this.ptCurrentCell.Y != -1); 25641DataGridViewCellStyle dataGridViewCellStyle = dataGridViewCurrentCell.GetInheritedStyle(null, this.ptCurrentCell.Y, true); 26133if (!committed && this.ptCurrentCell.X >= 0 && 26135forCurrentCellChange && (this.ptCurrentCell.X != columnIndex || this.ptCurrentCell.Y != rowIndex), 26136this.ptCurrentCell.Y != rowIndex /*forCurrentRowChange*/)) 26150if (!committed && this.ptCurrentCell.X >= 0 && 26152forCurrentCellChange && (this.ptCurrentCell.X != columnIndex || this.ptCurrentCell.Y != rowIndex), 26153this.ptCurrentCell.Y != rowIndex /*forCurrentRowChange*/)) 26163if (!committed && this.ptCurrentCell.X >= 0 && 26165forCurrentCellChange && (this.ptCurrentCell.X != columnIndex || this.ptCurrentCell.Y != rowIndex), 26166this.ptCurrentCell.Y != rowIndex /*forCurrentRowChange*/)) 26318if (this.ptCurrentCell.X >= 0 && 26319(this.ptCurrentCell.X != columnIndex || this.ptCurrentCell.Y != rowIndex)) 26378if (!committed && this.ptCurrentCell.X >= 0 && 26380forCurrentCellChange && (this.ptCurrentCell.X != columnIndex || this.ptCurrentCell.Y != rowIndex), 26381this.ptCurrentCell.Y != rowIndex /*forCurrentRowChange*/)) 26407if (!committed && this.ptCurrentCell.X >= 0 && 26409forCurrentCellChange && (this.ptCurrentCell.X != columnIndex || this.ptCurrentCell.Y != rowIndex), 26410this.ptCurrentCell.Y != rowIndex /*forCurrentRowChange*/)) 26456(this.Rows.GetRowState(this.ptCurrentCell.Y) & DataGridViewElementStates.Frozen) == 0) 26867if (this.ptCurrentCell.X != columnIndex || this.ptCurrentCell.Y != rowIndex) 26872this.ptCurrentCell.X = columnIndex; 26873this.ptCurrentCell.Y = rowIndex; 26886int oldCurrentCellX = this.ptCurrentCell.X; 26887int oldCurrentCellY = this.ptCurrentCell.Y; 26926Debug.Assert(oldCurrentCellX == this.ptCurrentCell.X); 26927Debug.Assert(oldCurrentCellY == this.ptCurrentCell.Y); 26991this.ptCurrentCell.X = columnIndex; 26992this.ptCurrentCell.Y = rowIndex; 27019OnCellEnter(ref dataGridViewCellTmp, this.ptCurrentCell.X, this.ptCurrentCell.Y); 27027if (oldCurrentCellY != this.ptCurrentCell.Y && this.RowHeadersVisible && oldCurrentCellY < this.Rows.Count) 27032InvalidateCellPrivate(this.ptCurrentCell.X, this.ptCurrentCell.Y); 27033if (this.RowHeadersVisible && oldCurrentCellY != this.ptCurrentCell.Y) 27035InvalidateCellPrivate(-1, this.ptCurrentCell.Y); 27038this.ptCurrentCell.X != -1 && 27054if (this.ptCurrentCell.X != -1) 27056AccessibilityNotifyCurrentCellChanged(new Point(this.ptCurrentCell.X, this.ptCurrentCell.Y)); 27082int oldCurrentCellX = this.ptCurrentCell.X; 27083int oldCurrentCellY = this.ptCurrentCell.Y; 27118Debug.Assert(oldCurrentCellX == this.ptCurrentCell.X); 27119Debug.Assert(oldCurrentCellY == this.ptCurrentCell.Y); 27135if (this.ptCurrentCell.X != -1) 27137this.ptCurrentCell.X = -1; 27138this.ptCurrentCell.Y = -1; 28235this.ptCurrentCellCache.X = this.ptCurrentCell.X; 28236this.ptCurrentCellCache.Y = this.ptCurrentCell.Y; 28553if (this.ptCurrentCell.X != -1) 28555dataGridViewColumn = this.Columns.GetNextColumn(this.Columns[this.ptCurrentCell.X], 28564if (this.ptCurrentCell.Y != -1) 28566nextVisibleRowIndex = this.Rows.GetNextRow(this.ptCurrentCell.Y, DataGridViewElementStates.Visible); 28573if (this.ptCurrentCell.X == -1) 28586targetRowIndex = this.ptCurrentCell.Y; 28600if (this.ptCurrentCell.X == -1) 28620if (this.ptCurrentCell.X == -1) 28640if (this.ptCurrentCell.X == -1) 28650if (targetRowIndex != this.ptCurrentCell.Y || this.MultiSelect) 28668if (this.ptCurrentCell.X == -1) 28710if (this.ptCurrentCell.X != -1) 28712dataGridViewColumn = this.Columns.GetPreviousColumn(this.Columns[this.ptCurrentCell.X], 28722if (this.ptCurrentCell.Y != -1) 28724previousVisibleRowIndex = this.Rows.GetPreviousRow(this.ptCurrentCell.Y, DataGridViewElementStates.Visible); 28739if (this.ptCurrentCell.X == -1) 28752targetRowIndex = this.ptCurrentCell.Y; 28766if (this.ptCurrentCell.X == -1) 28786if (this.ptCurrentCell.X == -1) 28806if (this.ptCurrentCell.X == -1) 28816if (targetRowIndex != this.ptCurrentCell.Y || this.MultiSelect) 28834if (this.ptCurrentCell.X == -1) 29144PositionEditingControl(rowIndex == -1 || this.ptCurrentCell.Y != rowIndex, true, false);