Loading common/common.cpp +5 −1 Original line number Original line Diff line number Diff line Loading @@ -246,9 +246,13 @@ void* MyMalloc( size_t nb_octets ) bool ProcessExecute( const wxString& aCommandLine, int aFlags ) bool ProcessExecute( const wxString& aCommandLine, int aFlags ) { { #ifdef __WINDOWS__ wxExecute(aCommandLine); return true; #else wxProcess* process = wxProcess::Open( aCommandLine, aFlags ); wxProcess* process = wxProcess::Open( aCommandLine, aFlags ); return process != NULL; return process != NULL; #endif } } Loading eeschema/block.cpp +1 −5 Original line number Original line Diff line number Diff line Loading @@ -934,7 +934,7 @@ void DeleteStruct( WinEDA_DrawPanel* panel, wxDC* DC, SCH_ITEM * DrawStruct ) /* Cette stucture est rattachee a une feuille, et n'est pas /* Cette stucture est rattachee a une feuille, et n'est pas * accessible par la liste globale directement */ * accessible par la liste globale directement */ frame->SaveCopyInUndoList( (SCH_ITEM*) ( (Hierarchical_PIN_Sheet_Struct*) DrawStruct )->m_Parent, IS_CHANGED ); frame->SaveCopyInUndoList( (SCH_ITEM*) ( (Hierarchical_PIN_Sheet_Struct*) DrawStruct )->m_Parent, IS_CHANGED ); frame->DeleteSheetLabel( DC, (Hierarchical_PIN_Sheet_Struct*) DrawStruct ); frame->DeleteSheetLabel( DC ? true : false , (Hierarchical_PIN_Sheet_Struct*) DrawStruct ); return; return; } } Loading Loading @@ -965,10 +965,6 @@ void DeleteStruct( WinEDA_DrawPanel* panel, wxDC* DC, SCH_ITEM * DrawStruct ) if( DrawStruct->Type() == DRAW_SHEET_STRUCT_TYPE ) if( DrawStruct->Type() == DRAW_SHEET_STRUCT_TYPE ) { { frame->SaveCopyInUndoList( DrawStruct, IS_DELETED ); // Currently In TEST frame->SaveCopyInUndoList( DrawStruct, IS_DELETED ); // Currently In TEST // SAFE_DELETE(DrawStruct); //no undo/redo for this (for now), it is on both the EEDrawList and m_SubSheet arrays, //hence the undo logic would have to be extended for this. } } else else frame->SaveCopyInUndoList( DrawStruct, IS_DELETED ); frame->SaveCopyInUndoList( DrawStruct, IS_DELETED ); Loading eeschema/class_drawsheet.cpp +9 −5 Original line number Original line Diff line number Diff line Loading @@ -240,16 +240,16 @@ void DrawSheetStruct::Place( WinEDA_SchematicFrame* frame, wxDC* DC ) /********************************************************************/ /********************************************************************/ void DrawSheetStruct::CleanupSheet( WinEDA_SchematicFrame* frame, wxDC* DC ) void DrawSheetStruct::CleanupSheet( WinEDA_SchematicFrame* aFrame, bool aRedraw ) /********************************************************************/ /********************************************************************/ /* Delete pinsheets which are not corresponding to a hierarchal label /* Delete pinsheets which are not corresponding to a hierarchal label * if DC != NULL, redraw Sheet * if aRedraw != NULL, redraw Sheet */ */ { { Hierarchical_PIN_Sheet_Struct* Pinsheet, * NextPinsheet; Hierarchical_PIN_Sheet_Struct* Pinsheet, * NextPinsheet; if( !IsOK( frame, _( "Ok to cleanup this sheet" ) ) ) if( !IsOK( aFrame, _( "Ok to cleanup this sheet" ) ) ) return; return; Pinsheet = m_Label; Pinsheet = m_Label; Loading @@ -272,11 +272,15 @@ void DrawSheetStruct::CleanupSheet( WinEDA_SchematicFrame* frame, wxDC* DC ) NextPinsheet = Pinsheet->Next(); NextPinsheet = Pinsheet->Next(); if( HLabel == NULL ) // Hlabel not found: delete pinsheet if( HLabel == NULL ) // Hlabel not found: delete pinsheet { { frame->GetScreen()->SetModify(); aFrame->GetScreen()->SetModify(); frame->DeleteSheetLabel( DC, Pinsheet ); aFrame->DeleteSheetLabel( false, Pinsheet ); } } Pinsheet = NextPinsheet; Pinsheet = NextPinsheet; } } if( aRedraw ) aFrame->DrawPanel->PostDirtyRect( GetBoundingBox() ); } } Loading eeschema/class_drawsheet.h +1 −1 Original line number Original line Diff line number Diff line Loading @@ -108,7 +108,7 @@ public: void Place( WinEDA_SchematicFrame* frame, wxDC* DC ); void Place( WinEDA_SchematicFrame* frame, wxDC* DC ); DrawSheetStruct* GenCopy(); DrawSheetStruct* GenCopy(); void Display_Infos( WinEDA_DrawFrame* frame ); void Display_Infos( WinEDA_DrawFrame* frame ); void CleanupSheet( WinEDA_SchematicFrame* frame, wxDC* DC ); void CleanupSheet( WinEDA_SchematicFrame* frame, bool aRedraw ); virtual void Draw( WinEDA_DrawPanel* panel, wxDC* DC, const wxPoint& offset, virtual void Draw( WinEDA_DrawPanel* panel, wxDC* DC, const wxPoint& offset, int draw_mode, int Color = -1 ); int draw_mode, int Color = -1 ); EDA_Rect GetBoundingBox(); EDA_Rect GetBoundingBox(); Loading eeschema/class_schematic_items.cpp +0 −1 Original line number Original line Diff line number Diff line Loading @@ -270,7 +270,6 @@ void DrawMarkerStruct::Show( int nestLevel, std::ostream& os ) bool DrawMarkerStruct::Save( FILE* aFile ) const bool DrawMarkerStruct::Save( FILE* aFile ) const { { bool success = true; bool success = true; wxString msg; if( fprintf( aFile, "Kmarq %c %-4d %-4d \"%s\" F=%X\n", if( fprintf( aFile, "Kmarq %c %-4d %-4d \"%s\" F=%X\n", int( m_Type ) + 'A', int( m_Type ) + 'A', Loading Loading
common/common.cpp +5 −1 Original line number Original line Diff line number Diff line Loading @@ -246,9 +246,13 @@ void* MyMalloc( size_t nb_octets ) bool ProcessExecute( const wxString& aCommandLine, int aFlags ) bool ProcessExecute( const wxString& aCommandLine, int aFlags ) { { #ifdef __WINDOWS__ wxExecute(aCommandLine); return true; #else wxProcess* process = wxProcess::Open( aCommandLine, aFlags ); wxProcess* process = wxProcess::Open( aCommandLine, aFlags ); return process != NULL; return process != NULL; #endif } } Loading
eeschema/block.cpp +1 −5 Original line number Original line Diff line number Diff line Loading @@ -934,7 +934,7 @@ void DeleteStruct( WinEDA_DrawPanel* panel, wxDC* DC, SCH_ITEM * DrawStruct ) /* Cette stucture est rattachee a une feuille, et n'est pas /* Cette stucture est rattachee a une feuille, et n'est pas * accessible par la liste globale directement */ * accessible par la liste globale directement */ frame->SaveCopyInUndoList( (SCH_ITEM*) ( (Hierarchical_PIN_Sheet_Struct*) DrawStruct )->m_Parent, IS_CHANGED ); frame->SaveCopyInUndoList( (SCH_ITEM*) ( (Hierarchical_PIN_Sheet_Struct*) DrawStruct )->m_Parent, IS_CHANGED ); frame->DeleteSheetLabel( DC, (Hierarchical_PIN_Sheet_Struct*) DrawStruct ); frame->DeleteSheetLabel( DC ? true : false , (Hierarchical_PIN_Sheet_Struct*) DrawStruct ); return; return; } } Loading Loading @@ -965,10 +965,6 @@ void DeleteStruct( WinEDA_DrawPanel* panel, wxDC* DC, SCH_ITEM * DrawStruct ) if( DrawStruct->Type() == DRAW_SHEET_STRUCT_TYPE ) if( DrawStruct->Type() == DRAW_SHEET_STRUCT_TYPE ) { { frame->SaveCopyInUndoList( DrawStruct, IS_DELETED ); // Currently In TEST frame->SaveCopyInUndoList( DrawStruct, IS_DELETED ); // Currently In TEST // SAFE_DELETE(DrawStruct); //no undo/redo for this (for now), it is on both the EEDrawList and m_SubSheet arrays, //hence the undo logic would have to be extended for this. } } else else frame->SaveCopyInUndoList( DrawStruct, IS_DELETED ); frame->SaveCopyInUndoList( DrawStruct, IS_DELETED ); Loading
eeschema/class_drawsheet.cpp +9 −5 Original line number Original line Diff line number Diff line Loading @@ -240,16 +240,16 @@ void DrawSheetStruct::Place( WinEDA_SchematicFrame* frame, wxDC* DC ) /********************************************************************/ /********************************************************************/ void DrawSheetStruct::CleanupSheet( WinEDA_SchematicFrame* frame, wxDC* DC ) void DrawSheetStruct::CleanupSheet( WinEDA_SchematicFrame* aFrame, bool aRedraw ) /********************************************************************/ /********************************************************************/ /* Delete pinsheets which are not corresponding to a hierarchal label /* Delete pinsheets which are not corresponding to a hierarchal label * if DC != NULL, redraw Sheet * if aRedraw != NULL, redraw Sheet */ */ { { Hierarchical_PIN_Sheet_Struct* Pinsheet, * NextPinsheet; Hierarchical_PIN_Sheet_Struct* Pinsheet, * NextPinsheet; if( !IsOK( frame, _( "Ok to cleanup this sheet" ) ) ) if( !IsOK( aFrame, _( "Ok to cleanup this sheet" ) ) ) return; return; Pinsheet = m_Label; Pinsheet = m_Label; Loading @@ -272,11 +272,15 @@ void DrawSheetStruct::CleanupSheet( WinEDA_SchematicFrame* frame, wxDC* DC ) NextPinsheet = Pinsheet->Next(); NextPinsheet = Pinsheet->Next(); if( HLabel == NULL ) // Hlabel not found: delete pinsheet if( HLabel == NULL ) // Hlabel not found: delete pinsheet { { frame->GetScreen()->SetModify(); aFrame->GetScreen()->SetModify(); frame->DeleteSheetLabel( DC, Pinsheet ); aFrame->DeleteSheetLabel( false, Pinsheet ); } } Pinsheet = NextPinsheet; Pinsheet = NextPinsheet; } } if( aRedraw ) aFrame->DrawPanel->PostDirtyRect( GetBoundingBox() ); } } Loading
eeschema/class_drawsheet.h +1 −1 Original line number Original line Diff line number Diff line Loading @@ -108,7 +108,7 @@ public: void Place( WinEDA_SchematicFrame* frame, wxDC* DC ); void Place( WinEDA_SchematicFrame* frame, wxDC* DC ); DrawSheetStruct* GenCopy(); DrawSheetStruct* GenCopy(); void Display_Infos( WinEDA_DrawFrame* frame ); void Display_Infos( WinEDA_DrawFrame* frame ); void CleanupSheet( WinEDA_SchematicFrame* frame, wxDC* DC ); void CleanupSheet( WinEDA_SchematicFrame* frame, bool aRedraw ); virtual void Draw( WinEDA_DrawPanel* panel, wxDC* DC, const wxPoint& offset, virtual void Draw( WinEDA_DrawPanel* panel, wxDC* DC, const wxPoint& offset, int draw_mode, int Color = -1 ); int draw_mode, int Color = -1 ); EDA_Rect GetBoundingBox(); EDA_Rect GetBoundingBox(); Loading
eeschema/class_schematic_items.cpp +0 −1 Original line number Original line Diff line number Diff line Loading @@ -270,7 +270,6 @@ void DrawMarkerStruct::Show( int nestLevel, std::ostream& os ) bool DrawMarkerStruct::Save( FILE* aFile ) const bool DrawMarkerStruct::Save( FILE* aFile ) const { { bool success = true; bool success = true; wxString msg; if( fprintf( aFile, "Kmarq %c %-4d %-4d \"%s\" F=%X\n", if( fprintf( aFile, "Kmarq %c %-4d %-4d \"%s\" F=%X\n", int( m_Type ) + 'A', int( m_Type ) + 'A', Loading