Commit 2047d873 authored by jean-pierre charras's avatar jean-pierre charras
Browse files

Minor fixes (Bug #1414328 and Bug #1440312). Remove translatable attribute in a debug message.

tools/edit_tool.cpp: remove limitation (GAL mode) to delete the last pad in a footprint (a footprint can have 0 pad, for instance a logo)
parent 5a02b91e
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -316,7 +316,7 @@ bool TOOL_MANAGER::RunAction( const std::string& aActionName, bool aNow, void* a
        return true;
    }

    wxASSERT_MSG( action != NULL, wxString::Format( _( "Could not find action %s." ), aActionName ) );
    wxASSERT_MSG( action != NULL, wxString::Format( wxT( "Could not find action %s." ), aActionName ) );

    return false;
}
+15 −2
Original line number Diff line number Diff line
@@ -151,7 +151,16 @@ bool TRACKS_CLEANER::CleanupBoard( PCB_EDIT_FRAME *aFrame,
    modified |= (aMergeSegments && clean_segments());

    // Delete dangling tracks
    modified |= (aDeleteUnconnected && deleteUnconnectedTracks());
    if( aDeleteUnconnected && deleteUnconnectedTracks() )
    {
        modified = true ;

        // Removed tracks can leave aligned segments
        // (when a T was formed by tracks and the "vertical" segment
        // is removed;
        if( aMergeSegments )
            clean_segments();
    }

    if( modified )
    {
@@ -161,6 +170,7 @@ bool TRACKS_CLEANER::CleanupBoard( PCB_EDIT_FRAME *aFrame,
        aFrame->Compile_Ratsnest( NULL, true );
        aFrame->OnModify();
    }

    return modified;
}

@@ -515,6 +525,7 @@ bool TRACKS_CLEANER::clean_segments()

    // merge collinear segments:
    TRACK *nextsegment;

    for( TRACK *segment = m_Brd->m_Track; segment; segment = nextsegment )
    {
        nextsegment = segment->Next();
@@ -522,10 +533,12 @@ bool TRACKS_CLEANER::clean_segments()
        if( segment->Type() == PCB_TRACE_T )
        {
            bool merged_this = merge_collinear_of_track( segment );
            modified |= merged_this;

            if( merged_this ) // The current segment was modified, retry to merge it again
            {
                nextsegment = segment->Next();
                modified = true;
            }
        }
    }

+1 −7
Original line number Diff line number Diff line
///////////////////////////////////////////////////////////////////////////
// C++ code generated with wxFormBuilder (version Apr 10 2012)
// C++ code generated with wxFormBuilder (version Jun  5 2014)
// http://www.wxformbuilder.org/
//
// PLEASE DO "NOT" EDIT THIS FILE!
@@ -101,20 +101,14 @@ DIALOG_GEN_MODULE_POSITION_BASE::DIALOG_GEN_MODULE_POSITION_BASE( wxWindow* pare
	this->Centre( wxBOTH );
	
	// Connect Events
	this->Connect( wxEVT_CLOSE_WINDOW, wxCloseEventHandler( DIALOG_GEN_MODULE_POSITION_BASE::OnClose ) );
	this->Connect( wxEVT_INIT_DIALOG, wxInitDialogEventHandler( DIALOG_GEN_MODULE_POSITION_BASE::OnInitDialog ) );
	m_browseButton->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_GEN_MODULE_POSITION_BASE::OnOutputDirectoryBrowseClicked ), NULL, this );
	m_sdbSizerButtonsCancel->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_GEN_MODULE_POSITION_BASE::OnCancelButton ), NULL, this );
	m_sdbSizerButtonsOK->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_GEN_MODULE_POSITION_BASE::OnOKButton ), NULL, this );
}

DIALOG_GEN_MODULE_POSITION_BASE::~DIALOG_GEN_MODULE_POSITION_BASE()
{
	// Disconnect Events
	this->Disconnect( wxEVT_CLOSE_WINDOW, wxCloseEventHandler( DIALOG_GEN_MODULE_POSITION_BASE::OnClose ) );
	this->Disconnect( wxEVT_INIT_DIALOG, wxInitDialogEventHandler( DIALOG_GEN_MODULE_POSITION_BASE::OnInitDialog ) );
	m_browseButton->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_GEN_MODULE_POSITION_BASE::OnOutputDirectoryBrowseClicked ), NULL, this );
	m_sdbSizerButtonsCancel->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_GEN_MODULE_POSITION_BASE::OnCancelButton ), NULL, this );
	m_sdbSizerButtonsOK->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_GEN_MODULE_POSITION_BASE::OnOKButton ), NULL, this );
	
}
+8 −6
Original line number Diff line number Diff line
<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<wxFormBuilder_Project>
    <FileVersion major="1" minor="11" />
    <FileVersion major="1" minor="13" />
    <object class="Project" expanded="1">
        <property name="class_decoration"></property>
        <property name="code_generation">C++</property>
@@ -20,8 +20,10 @@
        <property name="path">.</property>
        <property name="precompiled_header"></property>
        <property name="relative_path">1</property>
        <property name="skip_lua_events">1</property>
        <property name="skip_php_events">1</property>
        <property name="skip_python_events">1</property>
        <property name="ui_table">UI</property>
        <property name="use_enum">1</property>
        <property name="use_microsoft_bom">0</property>
        <object class="Dialog" expanded="1">
@@ -59,13 +61,13 @@
            <event name="OnAuiPaneRestore"></event>
            <event name="OnAuiRender"></event>
            <event name="OnChar"></event>
            <event name="OnClose">OnClose</event>
            <event name="OnClose"></event>
            <event name="OnEnterWindow"></event>
            <event name="OnEraseBackground"></event>
            <event name="OnHibernate"></event>
            <event name="OnIconize"></event>
            <event name="OnIdle"></event>
            <event name="OnInitDialog">OnInitDialog</event>
            <event name="OnInitDialog"></event>
            <event name="OnKeyDown"></event>
            <event name="OnKeyUp"></event>
            <event name="OnKillFocus"></event>
@@ -236,7 +238,7 @@
                                                <property name="max_size"></property>
                                                <property name="maximize_button">0</property>
                                                <property name="maximum_size"></property>
                                                <property name="maxlength">0</property>
                                                <property name="maxlength"></property>
                                                <property name="min_size"></property>
                                                <property name="minimize_button">0</property>
                                                <property name="minimum_size">350,-1</property>
@@ -714,7 +716,7 @@
                                <property name="max_size"></property>
                                <property name="maximize_button">0</property>
                                <property name="maximum_size"></property>
                                <property name="maxlength">0</property>
                                <property name="maxlength"></property>
                                <property name="min_size"></property>
                                <property name="minimize_button">0</property>
                                <property name="minimum_size">-1,150</property>
@@ -789,7 +791,7 @@
                        <property name="name">m_sdbSizerButtons</property>
                        <property name="permission">protected</property>
                        <event name="OnApplyButtonClick"></event>
                        <event name="OnCancelButtonClick">OnCancelButton</event>
                        <event name="OnCancelButtonClick"></event>
                        <event name="OnContextHelpButtonClick"></event>
                        <event name="OnHelpButtonClick"></event>
                        <event name="OnNoButtonClick"></event>
+3 −4
Original line number Diff line number Diff line
///////////////////////////////////////////////////////////////////////////
// C++ code generated with wxFormBuilder (version Apr 10 2012)
// C++ code generated with wxFormBuilder (version Jun  5 2014)
// http://www.wxformbuilder.org/
//
// PLEASE DO "NOT" EDIT THIS FILE!
@@ -11,6 +11,8 @@
#include <wx/artprov.h>
#include <wx/xrc/xmlres.h>
#include <wx/intl.h>
class DIALOG_SHIM;

#include "dialog_shim.h"
#include <wx/string.h>
#include <wx/stattext.h>
@@ -48,10 +50,7 @@ class DIALOG_GEN_MODULE_POSITION_BASE : public DIALOG_SHIM
		wxButton* m_sdbSizerButtonsCancel;
		
		// Virtual event handlers, overide them in your derived class
		virtual void OnClose( wxCloseEvent& event ) { event.Skip(); }
		virtual void OnInitDialog( wxInitDialogEvent& event ) { event.Skip(); }
		virtual void OnOutputDirectoryBrowseClicked( wxCommandEvent& event ) { event.Skip(); }
		virtual void OnCancelButton( wxCommandEvent& event ) { event.Skip(); }
		virtual void OnOKButton( wxCommandEvent& event ) { event.Skip(); }
		
	
Loading