From 77488e379cdbb0627b6eb107d30c83693f9fb048 Mon Sep 17 00:00:00 2001 From: Seth Hillbrand Date: Wed, 21 Aug 2019 22:50:26 -0700 Subject: [PATCH] gerbview: Ensure selection lives on top Just picking the next layer will be overwritten when we have multiple objects on the same layer in gerbview. Move the selection to the top to ensure it is out top-most layer when drawing. Fixes: lp:1833868 * https://bugs.launchpad.net/kicad/+bug/1833868 --- gerbview/tools/gerbview_selection_tool.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gerbview/tools/gerbview_selection_tool.cpp b/gerbview/tools/gerbview_selection_tool.cpp index a6843291c3..d2a5d00e6b 100644 --- a/gerbview/tools/gerbview_selection_tool.cpp +++ b/gerbview/tools/gerbview_selection_tool.cpp @@ -525,7 +525,7 @@ void GERBVIEW_SELECTION_TOOL::select( EDA_ITEM* aItem ) return; m_selection.Add( aItem ); - getView()->Add( &m_selection ); + getView()->Add( &m_selection, std::numeric_limits::max() ); selectVisually( aItem ); }