Prevent UI events during footprint dialog ctor
Errors may get thrown when the 3d models are loaded for missing search paths. This triggers the idle event that makes assumptions about the state of the dialog. We halt event handling until the ctor finishes. Fixes https://gitlab.com/kicad/code/kicad/issues/12944
This commit is contained in:
parent
3253bd9a3d
commit
be86e9f57f
|
@ -70,6 +70,7 @@ DIALOG_FOOTPRINT_PROPERTIES_FP_EDITOR::DIALOG_FOOTPRINT_PROPERTIES_FP_EDITOR(
|
||||||
m_solderPasteRatio( aParent, m_PasteMarginRatioLabel, m_PasteMarginRatioCtrl,
|
m_solderPasteRatio( aParent, m_PasteMarginRatioLabel, m_PasteMarginRatioCtrl,
|
||||||
m_PasteMarginRatioUnits )
|
m_PasteMarginRatioUnits )
|
||||||
{
|
{
|
||||||
|
SetEvtHandlerEnabled( false );
|
||||||
// Create the 3D models page
|
// Create the 3D models page
|
||||||
m_3dPanel = new PANEL_FP_PROPERTIES_3D_MODEL( m_frame, m_footprint, this, m_NoteBook );
|
m_3dPanel = new PANEL_FP_PROPERTIES_3D_MODEL( m_frame, m_footprint, this, m_NoteBook );
|
||||||
m_NoteBook->AddPage( m_3dPanel, _("3D Models"), false );
|
m_NoteBook->AddPage( m_3dPanel, _("3D Models"), false );
|
||||||
|
@ -145,6 +146,7 @@ DIALOG_FOOTPRINT_PROPERTIES_FP_EDITOR::DIALOG_FOOTPRINT_PROPERTIES_FP_EDITOR(
|
||||||
nullptr, this );
|
nullptr, this );
|
||||||
|
|
||||||
finishDialogSettings();
|
finishDialogSettings();
|
||||||
|
SetEvtHandlerEnabled( true );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue