From 6bad88e592c9c62c297d89d0bd216729f49369d9 Mon Sep 17 00:00:00 2001 From: Jeff Young Date: Sat, 27 Aug 2022 23:57:45 +0100 Subject: [PATCH] Make external hypertext links show a menu before executing. --- eeschema/tools/sch_navigate_tool.cpp | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/eeschema/tools/sch_navigate_tool.cpp b/eeschema/tools/sch_navigate_tool.cpp index c568b74bc7..f9cf6fe95f 100644 --- a/eeschema/tools/sch_navigate_tool.cpp +++ b/eeschema/tools/sch_navigate_tool.cpp @@ -81,7 +81,12 @@ void SCH_NAVIGATE_TOOL::HypertextCommand( const wxString& href ) } else { - GetAssociatedDocument( m_frame, href, &m_frame->Prj() ); + wxMenu menu; + + menu.Append( 1, wxString::Format( _( "Open %s" ), href ) ); + + if( m_frame->GetPopupMenuSelectionFromUser( menu ) == 1 ) + GetAssociatedDocument( m_frame, href, &m_frame->Prj() ); } }