Formatting.

This commit is contained in:
Jeff Young 2024-06-24 14:14:03 +01:00
parent 968ef0082d
commit 561106bd01
1 changed files with 39 additions and 39 deletions

View File

@ -305,9 +305,8 @@ void SCH_EDIT_FRAME::PutDataInPreviousState( PICKED_ITEMS_LIST* aList )
SCH_ITEM* schItem = dynamic_cast<SCH_ITEM*>( eda_item ); SCH_ITEM* schItem = dynamic_cast<SCH_ITEM*>( eda_item );
// Set connectable object connectivity status. // Set connectable object connectivity status.
auto updateConnectivityFlag = [&, this]() auto updateConnectivityFlag =
{ [&]()
if( schItem )
{ {
if( schItem->IsConnectable() ) if( schItem->IsConnectable() )
{ {
@ -335,11 +334,11 @@ void SCH_EDIT_FRAME::PutDataInPreviousState( PICKED_ITEMS_LIST* aList )
m_highlightedConnChanged = true; m_highlightedConnChanged = true;
dirtyConnectivity = true; dirtyConnectivity = true;
// Do a local clean up if there are any connectable objects in the commit. // Do a local clean up if there are any connectable objects in the commit
if( connectivityCleanUp == NO_CLEANUP ) if( connectivityCleanUp == NO_CLEANUP )
connectivityCleanUp = LOCAL_CLEANUP; connectivityCleanUp = LOCAL_CLEANUP;
// Do a full rebauild of the connectivity if there is a sheet in the commit. // Do a full rebauild of the connectivity if there is a sheet in the commit
if( schItem->Type() == SCH_SHEET_T ) if( schItem->Type() == SCH_SHEET_T )
connectivityCleanUp = GLOBAL_CLEANUP; connectivityCleanUp = GLOBAL_CLEANUP;
} }
@ -347,11 +346,11 @@ void SCH_EDIT_FRAME::PutDataInPreviousState( PICKED_ITEMS_LIST* aList )
{ {
dirtyConnectivity = true; dirtyConnectivity = true;
} }
}
}; };
if( status == UNDO_REDO::NEWITEM ) if( status == UNDO_REDO::NEWITEM )
{ {
if( schItem )
updateConnectivityFlag(); updateConnectivityFlag();
// If we are removing the current sheet, get out first // If we are removing the current sheet, get out first
@ -373,6 +372,7 @@ void SCH_EDIT_FRAME::PutDataInPreviousState( PICKED_ITEMS_LIST* aList )
if( eda_item->Type() == SCH_SHEET_T ) if( eda_item->Type() == SCH_SHEET_T )
rebuildHierarchyNavigator = true; rebuildHierarchyNavigator = true;
if( schItem )
updateConnectivityFlag(); updateConnectivityFlag();
// deleted items are re-inserted on undo // deleted items are re-inserted on undo