Don't set modified flag for render settings in modedit.

Fixes: lp:1744521
* https://bugs.launchpad.net/kicad/+bug/1744521
This commit is contained in:
Jeff Young 2018-02-15 22:18:07 +00:00 committed by Wayne Stambaugh
parent ce0d1aca8d
commit 24b5152240
1 changed files with 7 additions and 4 deletions

View File

@ -669,10 +669,13 @@ void PCB_LAYER_WIDGET::OnRenderEnable( int aId, bool isEnabled )
BOARD* brd = myframe->GetBoard(); BOARD* brd = myframe->GetBoard();
wxASSERT( aId > GAL_LAYER_ID_START && aId < GAL_LAYER_ID_END ); wxASSERT( aId > GAL_LAYER_ID_START && aId < GAL_LAYER_ID_END );
// The layer visibility status is saved in the board file so set the board modified if( myframe->IsType( FRAME_PCB ) )
// state so the user has the option to save the changes. {
if( brd->IsElementVisible( static_cast<GAL_LAYER_ID>( aId ) ) != isEnabled ) // The layer visibility status is saved in the board file so set the board
myframe->OnModify(); // modified state so the user has the option to save the changes.
if( brd->IsElementVisible( static_cast<GAL_LAYER_ID>( aId ) ) != isEnabled )
myframe->OnModify();
}
brd->SetElementVisibility( static_cast<GAL_LAYER_ID>( aId ), isEnabled ); brd->SetElementVisibility( static_cast<GAL_LAYER_ID>( aId ), isEnabled );