fixed TCollectionPropertEditor deleting collection item, when not in sync

git-svn-id: trunk@6873 -
This commit is contained in:
mattias 2005-03-02 11:49:29 +00:00
parent a2e6b02e8c
commit b33ad8e14d

View File

@ -3516,7 +3516,6 @@ begin
if NewItemIndex=i then NewItemIndex:=-1;
end;
CollectionListBox.ItemIndex := -1;
CollectionListBox.Items.Delete(i);
if NewItemIndex>i then dec(NewItemIndex);
//debugln('TCollectionPropertyEditorForm.DeleteClick A NewItemIndex=',dbgs(NewItemIndex),' ItemIndex=',dbgs(CollectionListBox.ItemIndex),' CollectionListBox.Items.Count=',dbgs(CollectionListBox.Items.Count),' Collection.Count=',dbgs(Collection.Count));
// unselect all items in OI (collections can act strange on delete)