Remove confirmation dialog when deleting footprints.

Very minor other fixes.
This commit is contained in:
jean-pierre charras 2015-11-18 19:59:24 +01:00
parent bbba5d5c47
commit 4749921bbc
5 changed files with 7 additions and 26 deletions

View File

@ -312,7 +312,7 @@ static void InitKiCadAboutNew( AboutAppInfo& info )
info.AddTranslator(
new Contributor( wxT( "Rafael Sokolowski" ), wxT( "rafael.sokolowski@web.de" ), wxT( "German (DE)" ), KiBitmapNew( lang_de_xpm ) ) );
info.AddTranslator(
new Contributor( wxT( "Kenta Yonekura" ), wxT( "midpika@hotmail.com" ), wxT( "Japanese (JA)" ), KiBitmapNew( lang_jp_xpm ) ) );
new Contributor( wxT( "Kenta Yonekura" ), wxT( "yoneken@kicad.jp" ), wxT( "Japanese (JA)" ), KiBitmapNew( lang_jp_xpm ) ) );
info.AddTranslator(
new Contributor( wxT( "Manolis Stefanis" ), wxT( "" ), wxT( "Greek (el_GR)" ), KiBitmapNew( lang_gr_xpm ) ) );
info.AddTranslator(
@ -328,9 +328,6 @@ static void InitKiCadAboutNew( AboutAppInfo& info )
info.AddTranslator(
new Contributor( wxT( "Evgeniy Ivanov" ), wxT( "evgeniy_p_ivanov@yahoo.ca" ), wxT( "Bulgarian (BG)" ), KiBitmapNew( lang_bg_xpm ) ) );
// TODO: are these all russian translators,
// placed them here now,
// or else align them below other language maintainer with mail adress
info.AddTranslator( new Contributor( wxT( "Remy Halvick" ), wxEmptyString, wxT( "Others" ) ) );
info.AddTranslator( new Contributor( wxT( "David Briscoe" ), wxEmptyString, wxT( "Others" ) ) );
info.AddTranslator( new Contributor( wxT( "Dominique Laigle" ), wxEmptyString, wxT( "Others" ) ) );

View File

@ -1105,9 +1105,8 @@ public:
* The ratsnest and pad list are recalculated
* @param aModule = footprint to delete
* @param aDC = currentDevice Context. if NULL: do not redraw new ratsnest
* @param aAskBeforeDeleting : if true: ask for confirmation before deleting
*/
bool Delete_Module( MODULE* aModule, wxDC* aDC, bool aAskBeforeDeleting );
bool Delete_Module( MODULE* aModule, wxDC* aDC );
/**
* Function Change_Side_Module

View File

@ -744,7 +744,7 @@ void PCB_EDIT_FRAME::Process_Special_Functions( wxCommandEvent& event )
break;
}
if( Delete_Module( (MODULE*) GetCurItem(), &dc, true ) )
if( Delete_Module( (MODULE*) GetCurItem(), &dc ) )
{
SetCurItem( NULL );
}
@ -1268,7 +1268,7 @@ void PCB_EDIT_FRAME::RemoveStruct( BOARD_ITEM* Item, wxDC* DC )
switch( Item->Type() )
{
case PCB_MODULE_T:
Delete_Module( (MODULE*) Item, DC, true );
Delete_Module( (MODULE*) Item, DC );
break;
case PCB_DIMENSION_T:

View File

@ -249,7 +249,7 @@ void MoveFootprint( EDA_DRAW_PANEL* aPanel, wxDC* aDC, const wxPoint& aPosition,
}
bool PCB_EDIT_FRAME::Delete_Module( MODULE* aModule, wxDC* aDC, bool aAskBeforeDeleting )
bool PCB_EDIT_FRAME::Delete_Module( MODULE* aModule, wxDC* aDC )
{
wxString msg;
@ -258,21 +258,6 @@ bool PCB_EDIT_FRAME::Delete_Module( MODULE* aModule, wxDC* aDC, bool aAskBeforeD
SetMsgPanel( aModule );
/* Confirm module delete. */
if( aAskBeforeDeleting )
{
msg.Printf( _( "Delete Footprint %s (value %s) ?" ),
GetChars( aModule->GetReference() ),
GetChars( aModule->GetValue() ) );
if( !IsOK( this, msg ) )
{
return false;
}
}
OnModify();
/* Remove module from list, and put it in undo command list */
m_Pcb->m_Modules.Remove( aModule );
aModule->SetState( IS_DELETED, true );
@ -285,6 +270,8 @@ bool PCB_EDIT_FRAME::Delete_Module( MODULE* aModule, wxDC* aDC, bool aAskBeforeD
if( aDC )
m_canvas->Refresh();
OnModify();
return true;
}

View File

@ -345,11 +345,9 @@ void PCB_EDIT_FRAME::End_Move_Zone_Corner_Or_Outlines( wxDC* DC, ZONE_CONTAINER*
SetCurItem( NULL ); // This outline can be deleted when merging outlines
// Combine zones if possible
wxBusyCursor dummy;
GetBoard()->OnAreaPolygonModified( &s_AuxiliaryList, aZone );
m_canvas->Refresh();
int ii = GetBoard()->GetAreaIndex( aZone ); // test if aZone exists
if( ii < 0 )