Initialize grid visibility in appearance panel constructor

Fixes https://gitlab.com/kicad/code/kicad/-/issues/8266
This commit is contained in:
Jon Evans 2021-04-22 22:10:48 -04:00
parent 075bd788eb
commit 263e026ac4
1 changed files with 3 additions and 0 deletions

View File

@ -547,6 +547,9 @@ APPEARANCE_CONTROLS::APPEARANCE_CONTROLS( PCB_BASE_FRAME* aParent, wxWindow* aFo
rebuildObjects();
OnBoardChanged();
// Grid visibility is loaded and set to the GAL before we are constructed
SetObjectVisible( LAYER_GRID, m_frame->IsGridVisible() );
Bind( wxEVT_COMMAND_MENU_SELECTED, &APPEARANCE_CONTROLS::OnLayerContextMenu, this,
ID_CHANGE_COLOR, ID_LAST_VALUE );
}