From 5a74b55074bfba24b11131f5879489ef964507c4 Mon Sep 17 00:00:00 2001 From: Jeff Young Date: Tue, 20 Nov 2018 22:58:40 +0000 Subject: [PATCH] Reset delayedFocusPage even if it's already the right page. Fixes: lp:1804315 * https://bugs.launchpad.net/kicad/+bug/1804315 --- pcbnew/dialogs/dialog_edit_footprint_for_fp_editor.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/pcbnew/dialogs/dialog_edit_footprint_for_fp_editor.cpp b/pcbnew/dialogs/dialog_edit_footprint_for_fp_editor.cpp index 7afef00ba9..c7b077f932 100644 --- a/pcbnew/dialogs/dialog_edit_footprint_for_fp_editor.cpp +++ b/pcbnew/dialogs/dialog_edit_footprint_for_fp_editor.cpp @@ -793,9 +793,11 @@ void DIALOG_FOOTPRINT_FP_EDITOR::OnUpdateUI( wxUpdateUIEvent& event ) // b) show the correct notebook page in the background before the error dialog comes up // when triggered from an OK or a notebook page change - if( m_delayedFocusPage >= 0 && m_NoteBook->GetSelection() != m_delayedFocusPage ) + if( m_delayedFocusPage >= 0 ) { - m_NoteBook->SetSelection( (unsigned) m_delayedFocusPage ); + if( m_NoteBook->GetSelection() != m_delayedFocusPage ) + m_NoteBook->SetSelection( (unsigned) m_delayedFocusPage ); + m_delayedFocusPage = -1; }