mirror of
https://gitlab.com/kicad/code/kicad.git
synced 2025-09-14 02:03:12 +02:00
Remove over-zealous assert (KICAD-SJZ).
Items can be deleted more than once (for instance, a global deletion of all zone will still try to clean-up teardrops at the end, deleting them a second time).
This commit is contained in:
parent
58b5dae1ee
commit
4d7cbed3a9
@ -58,21 +58,21 @@ COMMIT& COMMIT::Stage( EDA_ITEM* aItem, CHANGE_TYPE aChangeType, BASE_SCREEN* aS
|
||||
break;
|
||||
|
||||
case CHT_REMOVE:
|
||||
wxASSERT( m_deletedItems.find( aItem ) == m_deletedItems.end() );
|
||||
m_deletedItems.insert( aItem );
|
||||
makeEntry( aItem, CHT_REMOVE | flag, makeImage( aItem ), aScreen );
|
||||
if( m_deletedItems.insert( aItem ).second )
|
||||
{
|
||||
makeEntry( aItem, CHT_REMOVE | flag, makeImage( aItem ), aScreen );
|
||||
|
||||
if( EDA_GROUP* parentGroup = aItem->GetParentGroup() )
|
||||
Modify( parentGroup->AsEdaItem(), aScreen, RECURSE_MODE::NO_RECURSE );
|
||||
if( EDA_GROUP* parentGroup = aItem->GetParentGroup() )
|
||||
Modify( parentGroup->AsEdaItem(), aScreen, RECURSE_MODE::NO_RECURSE );
|
||||
}
|
||||
|
||||
break;
|
||||
|
||||
case CHT_MODIFY:
|
||||
{
|
||||
EDA_ITEM* parent = parentObject( aItem );
|
||||
createModified( parent, makeImage( parent ), flag, aScreen );
|
||||
if( EDA_ITEM* parent = parentObject( aItem ) )
|
||||
createModified( parent, makeImage( parent ), flag, aScreen );
|
||||
|
||||
break;
|
||||
}
|
||||
|
||||
default:
|
||||
wxFAIL;
|
||||
|
Loading…
x
Reference in New Issue
Block a user