From 129fa52b65aa31e7feda1fea75c44b8f9739af54 Mon Sep 17 00:00:00 2001 From: Wayne Stambaugh Date: Tue, 11 Oct 2016 13:40:23 -0400 Subject: [PATCH] CvPcb: remove broken footprint documentation feature. At one point, all of the footprints provided by the KiCad footprint libraries were merged into a single pdf file. The link to open this file was provided on the toolbar. Since the footprint libraries have been split out into individual repositories, this file is no longer created so the toolbar button and the underlying code to open this file were removed. Improve a few CvPcb menu strings. Fixes lp:702785 https://bugs.launchpad.net/ubuntu/+source/kicad/+bug/702785 --- cvpcb/cvpcb_mainframe.cpp | 7 ------- cvpcb/menubar.cpp | 18 +++++++++--------- cvpcb/tool_cvpcb.cpp | 7 +------ include/id.h | 6 ++---- 4 files changed, 12 insertions(+), 26 deletions(-) diff --git a/cvpcb/cvpcb_mainframe.cpp b/cvpcb/cvpcb_mainframe.cpp index e2bdb76433..495a47b365 100644 --- a/cvpcb/cvpcb_mainframe.cpp +++ b/cvpcb/cvpcb_mainframe.cpp @@ -85,7 +85,6 @@ BEGIN_EVENT_TABLE( CVPCB_MAINFRAME, KIWAY_PLAYER ) EVT_TOOL( ID_CVPCB_GOTO_PREVIOUSNA, CVPCB_MAINFRAME::ToPreviousNA ) EVT_TOOL( ID_CVPCB_DEL_ASSOCIATIONS, CVPCB_MAINFRAME::DelAssociations ) EVT_TOOL( ID_CVPCB_AUTO_ASSOCIE, CVPCB_MAINFRAME::AutomaticFootprintMatching ) - EVT_TOOL( ID_PCB_DISPLAY_FOOTPRINT_DOC, CVPCB_MAINFRAME::DisplayDocFile ) EVT_TOOL( ID_CVPCB_FOOTPRINT_DISPLAY_FILTERED_LIST, CVPCB_MAINFRAME::OnSelectFilteringFootprint ) EVT_TOOL( ID_CVPCB_FOOTPRINT_DISPLAY_PIN_FILTERED_LIST, @@ -473,12 +472,6 @@ void CVPCB_MAINFRAME::DisplayModule( wxCommandEvent& event ) } -void CVPCB_MAINFRAME::DisplayDocFile( wxCommandEvent& event ) -{ - GetAssociatedDocument( this, m_DocModulesFileName, &Kiface().KifaceSearch() ); -} - - void CVPCB_MAINFRAME::OnSelectComponent( wxListEvent& event ) { if( m_skipComponentSelect ) diff --git a/cvpcb/menubar.cpp b/cvpcb/menubar.cpp index 6d6ff3aaa2..543c0613a5 100644 --- a/cvpcb/menubar.cpp +++ b/cvpcb/menubar.cpp @@ -2,7 +2,7 @@ * This program source code file is part of KiCad, a free EDA CAD application. * * Copyright (C) 2004 Jean-Pierre Charras, jaen-pierre.charras@gipsa-lab.inpg.com - * Copyright (C) 2004-2011 KiCad Developers, see change_log.txt for contributors. + * Copyright (C) 2004-2016 KiCad Developers, see change_log.txt for contributors. * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License @@ -62,7 +62,7 @@ void CVPCB_MAINFRAME::ReCreateMenuBar() // Save the footprints back into eeschema AddMenuItem( filesMenu, wxID_SAVE, - _( "&Save Footprint Association\tCtrl+S" ), + _( "&Save Footprint Associations\tCtrl+S" ), _( "Save footprint association in schematic component footprint fields" ), KiBitmap( save_xpm ) ); @@ -90,9 +90,9 @@ void CVPCB_MAINFRAME::ReCreateMenuBar() preferencesMenu->AppendSeparator(); AddMenuItem( preferencesMenu, ID_CVPCB_EQUFILES_LIST_EDIT, - _( "Edit &Equ Files List" ), - _( "Setup equ files list (.equ files)\n" - "They are files which give the footprint name from the component value"), + _( "&Edit Footprint Association File" ), + _( "Modify footprint association file (.equ). This is the file which " + "assigns the footprint name by the component value" ), KiBitmap( library_table_xpm ) ); preferencesMenu->AppendSeparator(); @@ -102,10 +102,10 @@ void CVPCB_MAINFRAME::ReCreateMenuBar() // Keep open on save data preferencesMenu->AppendSeparator(); AddMenuItem( preferencesMenu, ID_CVPCB_CONFIG_KEEP_OPEN_ON_SAVE, - _( "&Keep Open On Save" ), - _( "Prevent CvPcb from exiting after saving netlist file" ), - KiBitmap( exit_xpm ), - wxITEM_CHECK ); + _( "&Keep Open On Save" ), + _( "Prevent CvPcb from exiting after saving netlist file" ), + KiBitmap( exit_xpm ), + wxITEM_CHECK ); // Menu Help: wxMenu* helpMenu = new wxMenu; diff --git a/cvpcb/tool_cvpcb.cpp b/cvpcb/tool_cvpcb.cpp index 12fd7da1ce..c1d3b23b2f 100644 --- a/cvpcb/tool_cvpcb.cpp +++ b/cvpcb/tool_cvpcb.cpp @@ -75,12 +75,7 @@ void CVPCB_MAINFRAME::ReCreateHToolbar() m_mainToolBar->AddTool( ID_CVPCB_DEL_ASSOCIATIONS, wxEmptyString, KiBitmap( delete_association_xpm ), - _( "Delete all associations (links)" ) ); - - m_mainToolBar->AddSeparator(); - m_mainToolBar->AddTool( ID_PCB_DISPLAY_FOOTPRINT_DOC, wxEmptyString, - KiBitmap( datasheet_xpm ), - _( "Display footprint documentation" ) ); + _( "Delete all footprint associations" ) ); m_mainToolBar->AddSeparator(); m_mainToolBar->AddTool( ID_CVPCB_FOOTPRINT_DISPLAY_FILTERED_LIST, diff --git a/include/id.h b/include/id.h index 1b7ddddd4f..c27dc5ac58 100644 --- a/include/id.h +++ b/include/id.h @@ -251,9 +251,6 @@ enum main_id ID_EDA_SOCKET_EVENT_SERV, ID_EDA_SOCKET_EVENT, - // Command IDs common to Pcbnew and CvPcb. - ID_PCB_DISPLAY_FOOTPRINT_DOC, - // Common to all ID_TB_OPTIONS_SELECT_UNIT_MM, ID_TB_OPTIONS_SELECT_UNIT_INCH, @@ -276,7 +273,8 @@ enum main_id // mainly we experienced issues related to wxUpdateUIEvent calls when 2 (or more) wxFrames // share the same ID in menus, mainly in menubars/toolbars // The reason is the fact wxWidgets propagates the wxUpdateUIEvent to all parent windows - // to find wxUpdateUIEvent event functions matching the menuitem IDs found when activate a menu in the first frame. + // to find wxUpdateUIEvent event functions matching the menuitem IDs found when activate a + // menu in the first frame. // Reserve ROOM_FOR_KICADMANAGER IDs, for Kicad manager // Change it if this count is too small.