eeschema: Remove Save All

Saving individual parts of a schematic can break the schematic.  This
moves the schematic save option to save all sheets rather than just the
current sheet.

Fixes: lp:1840383
* https://bugs.launchpad.net/kicad/+bug/1840383
This commit is contained in:
Seth Hillbrand 2019-08-27 20:19:20 -07:00
parent ebbb12e978
commit 0d3f6a4930
4 changed files with 3 additions and 13 deletions

View File

@ -78,7 +78,6 @@ void SCH_EDIT_FRAME::ReCreateMenuBar()
fileMenu->AddItem( ACTIONS::save, modifiedDocumentCondition );
fileMenu->AddItem( ACTIONS::saveAs, EE_CONDITIONS::ShowAlways );
fileMenu->AddItem( ACTIONS::saveAll, modifiedDocumentCondition );
fileMenu->AddSeparator();

View File

@ -53,7 +53,7 @@ void SCH_EDIT_FRAME::ReCreateHToolbar()
m_mainToolBar->Add( ACTIONS::open );
}
m_mainToolBar->Add( ACTIONS::saveAll );
m_mainToolBar->Add( ACTIONS::save );
KiScaledSeparator( m_mainToolBar, this );
m_mainToolBar->Add( ACTIONS::pageSettings );
@ -172,7 +172,7 @@ void SCH_EDIT_FRAME::SyncToolbars()
KIGFX::GAL_DISPLAY_OPTIONS& galOpts = GetGalDisplayOptions();
SCH_SHEET_LIST sheetList( g_RootSheet );
m_mainToolBar->Toggle( ACTIONS::saveAll, sheetList.IsModified() );
m_mainToolBar->Toggle( ACTIONS::save, sheetList.IsModified() );
m_mainToolBar->Toggle( ACTIONS::undo, GetScreen() && GetScreen()->GetUndoCommandCount() > 0 );
m_mainToolBar->Toggle( ACTIONS::redo, GetScreen() && GetScreen()->GetRedoCommandCount() > 0 );
TOGGLE_TOOL( m_mainToolBar, ACTIONS::zoomTool );

View File

@ -68,7 +68,7 @@ int SCH_EDITOR_CONTROL::Open( const TOOL_EVENT& aEvent )
int SCH_EDITOR_CONTROL::Save( const TOOL_EVENT& aEvent )
{
m_frame->Save_File();
m_frame->SaveProject();
return 0;
}
@ -80,13 +80,6 @@ int SCH_EDITOR_CONTROL::SaveAs( const TOOL_EVENT& aEvent )
}
int SCH_EDITOR_CONTROL::SaveAll( const TOOL_EVENT& aEvent )
{
m_frame->SaveProject();
return 0;
}
int SCH_EDITOR_CONTROL::PageSetup( const TOOL_EVENT& aEvent )
{
PICKED_ITEMS_LIST undoCmd;
@ -1260,7 +1253,6 @@ void SCH_EDITOR_CONTROL::setTransitions()
Go( &SCH_EDITOR_CONTROL::Open, ACTIONS::open.MakeEvent() );
Go( &SCH_EDITOR_CONTROL::Save, ACTIONS::save.MakeEvent() );
Go( &SCH_EDITOR_CONTROL::SaveAs, ACTIONS::saveAs.MakeEvent() );
Go( &SCH_EDITOR_CONTROL::SaveAll, ACTIONS::saveAll.MakeEvent() );
Go( &SCH_EDITOR_CONTROL::PageSetup, ACTIONS::pageSettings.MakeEvent() );
Go( &SCH_EDITOR_CONTROL::Print, ACTIONS::print.MakeEvent() );
Go( &SCH_EDITOR_CONTROL::Plot, ACTIONS::plot.MakeEvent() );

View File

@ -52,7 +52,6 @@ public:
int Open( const TOOL_EVENT& aEvent );
int Save( const TOOL_EVENT& aEvent );
int SaveAs( const TOOL_EVENT& aEvent );
int SaveAll( const TOOL_EVENT& aEvent );
int PageSetup( const TOOL_EVENT& aEvent );
int Print( const TOOL_EVENT& aEvent );
int Plot( const TOOL_EVENT& aEvent );