Browse Source

Put up infobar when editing board footprint.

Fixes https://gitlab.com/kicad/code/kicad/issues/5294
pull/16/head
Jeff Young 5 years ago
parent
commit
d71d127c1a
  1. 12
      eeschema/libedit/lib_edit_frame.cpp
  2. 10
      pcbnew/footprint_edit_frame.cpp

12
eeschema/libedit/lib_edit_frame.cpp

@ -593,6 +593,18 @@ void LIB_EDIT_FRAME::SetCurPart( LIB_PART* aPart )
// Ensure synchronized pin edit can be enabled only symbols with interchangeable units
m_SyncPinEdit = aPart && aPart->IsRoot() && aPart->IsMulti() && !aPart->UnitsLocked();
/* TODO: enable when we have schematic-symbol editing...
if( IsCurrentPartFromSchematic() )
{
wxString msg;
msg.Printf( _( "Editing %s from schematic. Saving will update the schematic only." ),
partName );
GetInfoBar()->RemoveAllButtons();
GetInfoBar()->ShowMessage( msg, wxICON_INFORMATION );
}
*/
m_toolManager->ResetTools( TOOL_BASE::MODEL_RELOAD );
RebuildView();
}

10
pcbnew/footprint_edit_frame.cpp

@ -406,6 +406,16 @@ void FOOTPRINT_EDIT_FRAME::AddModuleToBoard( MODULE* aFootprint )
PCB_BASE_EDIT_FRAME::AddModuleToBoard( aFootprint );
if( IsCurrentFPFromBoard() )
{
wxString msg;
msg.Printf( _( "Editing %s from board. Saving will update the board only." ),
aFootprint->GetReference() );
GetInfoBar()->RemoveAllButtons();
GetInfoBar()->ShowMessage( msg, wxICON_INFORMATION );
}
UpdateMsgPanel();
}

Loading…
Cancel
Save