Bugzilla – Attachment 270536 Details for
Bug 472968
DataGridViewRowCollection.Insert is broken
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
IDP Log In
|
Forgot Password
[patch]
Patch
patch (text/plain), 882 bytes, created by
Mario Carrion
on 2009-02-05 18:06:13 UTC
(
hide
)
Description:
Patch
Filename:
MIME Type:
Creator:
Mario Carrion
Created:
2009-02-05 18:06:13 UTC
Size:
882 bytes
patch
obsolete
>Index: System.Windows.Forms/DataGridViewRowCollection.cs >=================================================================== >--- System.Windows.Forms/DataGridViewRowCollection.cs (revision 125891) >+++ System.Windows.Forms/DataGridViewRowCollection.cs (working copy) >@@ -404,7 +404,11 @@ > dataGridViewRow.SetIndex (rowIndex); > dataGridViewRow.SetDataGridView (dataGridView); > CompleteRowCells (dataGridViewRow); >- list[rowIndex] = dataGridViewRow; >+ list.Insert (rowIndex, dataGridViewRow); >+ for (int newIndex = rowIndex; newIndex < list.Count; newIndex++) { >+ DataGridViewRow row = (DataGridViewRow) list [newIndex]; >+ row.SetIndex (newIndex + 1); >+ } > OnCollectionChanged (new CollectionChangeEventArgs (CollectionChangeAction.Add, dataGridViewRow)); > if (raiseEvent) > DataGridView.OnRowsAdded (new DataGridViewRowsAddedEventArgs (rowIndex, 1)); >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
Actions:
View
|
Diff
Attachments on
bug 472968
:
270515
|
270516
|
270519
|
270532
|
270536
|
270550