Commit 0d530fb3 authored by jean-pierre charras's avatar jean-pierre charras

dialog_edit_component_in_schematic: moved "Reset to Library Default" Button....

dialog_edit_component_in_schematic: moved "Reset to Library Default" Button. This command is now undoable.
parent 05287607
...@@ -789,6 +789,10 @@ void DIALOG_EDIT_COMPONENT_IN_SCHEMATIC::SetInitCmp( wxCommandEvent& event ) ...@@ -789,6 +789,10 @@ void DIALOG_EDIT_COMPONENT_IN_SCHEMATIC::SetInitCmp( wxCommandEvent& event )
if( entry == NULL ) if( entry == NULL )
return; return;
// save old cmp in undo list if not already in edit, or moving ...
if( m_Cmp->m_Flags == 0 )
m_Parent->SaveCopyInUndoList( m_Cmp, UR_CHANGED );
INSTALL_DC( dc, m_Parent->DrawPanel ); INSTALL_DC( dc, m_Parent->DrawPanel );
RedrawOneStruct( m_Parent->DrawPanel, &dc, m_Cmp, g_XorMode ); RedrawOneStruct( m_Parent->DrawPanel, &dc, m_Cmp, g_XorMode );
......
This source diff could not be displayed because it is too large. You can view the blob instead.
/////////////////////////////////////////////////////////////////////////// ///////////////////////////////////////////////////////////////////////////
// C++ code generated with wxFormBuilder (version Apr 16 2008) // C++ code generated with wxFormBuilder (version Apr 16 2008)
// http://www.wxformbuilder.org/ // http://www.wxformbuilder.org/
// //
// PLEASE DO "NOT" EDIT THIS FILE! // PLEASE DO "NOT" EDIT THIS FILE!
/////////////////////////////////////////////////////////////////////////// ///////////////////////////////////////////////////////////////////////////
#ifndef __dialog_edit_component_in_schematic_fbp__ #ifndef __dialog_edit_component_in_schematic_fbp__
#define __dialog_edit_component_in_schematic_fbp__ #define __dialog_edit_component_in_schematic_fbp__
#include <wx/intl.h> #include <wx/intl.h>
#include <wx/string.h> #include <wx/string.h>
#include <wx/choice.h> #include <wx/choice.h>
#include <wx/gdicmn.h> #include <wx/gdicmn.h>
#include <wx/font.h> #include <wx/font.h>
#include <wx/colour.h> #include <wx/colour.h>
#include <wx/settings.h> #include <wx/settings.h>
#include <wx/sizer.h> #include <wx/sizer.h>
#include <wx/statbox.h> #include <wx/statbox.h>
#include <wx/radiobox.h> #include <wx/radiobox.h>
#include <wx/textctrl.h> #include <wx/textctrl.h>
#include <wx/checkbox.h> #include <wx/checkbox.h>
#include <wx/stattext.h> #include <wx/stattext.h>
#include <wx/listctrl.h> #include <wx/button.h>
#include <wx/button.h> #include <wx/listctrl.h>
#include <wx/dialog.h> #include <wx/dialog.h>
/////////////////////////////////////////////////////////////////////////// ///////////////////////////////////////////////////////////////////////////
/////////////////////////////////////////////////////////////////////////////// ///////////////////////////////////////////////////////////////////////////////
/// Class DIALOG_EDIT_COMPONENT_IN_SCHEMATIC_FBP /// Class DIALOG_EDIT_COMPONENT_IN_SCHEMATIC_FBP
/////////////////////////////////////////////////////////////////////////////// ///////////////////////////////////////////////////////////////////////////////
class DIALOG_EDIT_COMPONENT_IN_SCHEMATIC_FBP : public wxDialog class DIALOG_EDIT_COMPONENT_IN_SCHEMATIC_FBP : public wxDialog
{ {
private: private:
protected: protected:
wxChoice* unitChoice; wxChoice* unitChoice;
wxRadioBox* orientationRadioBox; wxRadioBox* orientationRadioBox;
wxRadioBox* mirrorRadioBox; wxRadioBox* mirrorRadioBox;
wxTextCtrl* chipnameTextCtrl; wxTextCtrl* chipnameTextCtrl;
wxCheckBox* convertCheckBox; wxCheckBox* convertCheckBox;
wxStaticText* partsAreLockedLabel; wxStaticText* partsAreLockedLabel;
wxListCtrl* fieldListCtrl; wxButton* defaultsButton;
wxButton* addFieldButton; wxListCtrl* fieldListCtrl;
wxButton* deleteFieldButton; wxButton* addFieldButton;
wxButton* moveUpButton; wxButton* deleteFieldButton;
wxCheckBox* showCheckBox; wxButton* moveUpButton;
wxCheckBox* rotateCheckBox; wxCheckBox* showCheckBox;
wxRadioBox* m_StyleRadioBox; wxCheckBox* rotateCheckBox;
wxStaticText* fieldNameLabel; wxRadioBox* m_StyleRadioBox;
wxTextCtrl* fieldNameTextCtrl; wxStaticText* fieldNameLabel;
wxStaticText* fieldValueLabel; wxTextCtrl* fieldNameTextCtrl;
wxTextCtrl* fieldValueTextCtrl; wxStaticText* fieldValueLabel;
wxStaticText* textSizeLabel; wxTextCtrl* fieldValueTextCtrl;
wxTextCtrl* textSizeTextCtrl; wxStaticText* textSizeLabel;
wxStaticText* posXLabel; wxTextCtrl* textSizeTextCtrl;
wxTextCtrl* posXTextCtrl; wxStaticText* posXLabel;
wxStaticText* posYLabel; wxTextCtrl* posXTextCtrl;
wxTextCtrl* posYTextCtrl; wxStaticText* posYLabel;
wxTextCtrl* posYTextCtrl;
wxButton* defaultsButton;
wxStdDialogButtonSizer* stdDialogButtonSizer; wxStdDialogButtonSizer* stdDialogButtonSizer;
wxButton* stdDialogButtonSizerOK; wxButton* stdDialogButtonSizerOK;
wxButton* stdDialogButtonSizerCancel; wxButton* stdDialogButtonSizerCancel;
// Virtual event handlers, overide them in your derived class // Virtual event handlers, overide them in your derived class
virtual void OnListItemDeselected( wxListEvent& event ){ event.Skip(); } virtual void SetInitCmp( wxCommandEvent& event ){ event.Skip(); }
virtual void OnListItemSelected( wxListEvent& event ){ event.Skip(); } virtual void OnListItemDeselected( wxListEvent& event ){ event.Skip(); }
virtual void addFieldButtonHandler( wxCommandEvent& event ){ event.Skip(); } virtual void OnListItemSelected( wxListEvent& event ){ event.Skip(); }
virtual void deleteFieldButtonHandler( wxCommandEvent& event ){ event.Skip(); } virtual void addFieldButtonHandler( wxCommandEvent& event ){ event.Skip(); }
virtual void moveUpButtonHandler( wxCommandEvent& event ){ event.Skip(); } virtual void deleteFieldButtonHandler( wxCommandEvent& event ){ event.Skip(); }
virtual void SetInitCmp( wxCommandEvent& event ){ event.Skip(); } virtual void moveUpButtonHandler( wxCommandEvent& event ){ event.Skip(); }
virtual void OnCancelButtonClick( wxCommandEvent& event ){ event.Skip(); } virtual void OnCancelButtonClick( wxCommandEvent& event ){ event.Skip(); }
virtual void OnOKButtonClick( wxCommandEvent& event ){ event.Skip(); } virtual void OnOKButtonClick( wxCommandEvent& event ){ event.Skip(); }
public: public:
DIALOG_EDIT_COMPONENT_IN_SCHEMATIC_FBP( wxWindow* parent, wxWindowID id = wxID_ANY, const wxString& title = _("Component Properties"), const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxSize( 864,640 ), long style = wxCAPTION|wxCLOSE_BOX|wxDEFAULT_DIALOG_STYLE|wxMAXIMIZE_BOX|wxMINIMIZE_BOX|wxRESIZE_BORDER|wxSYSTEM_MENU ); DIALOG_EDIT_COMPONENT_IN_SCHEMATIC_FBP( wxWindow* parent, wxWindowID id = wxID_ANY, const wxString& title = _("Component Properties"), const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxSize( 630,520 ), long style = wxCAPTION|wxCLOSE_BOX|wxDEFAULT_DIALOG_STYLE|wxMAXIMIZE_BOX|wxMINIMIZE_BOX|wxRESIZE_BORDER|wxSYSTEM_MENU );
~DIALOG_EDIT_COMPONENT_IN_SCHEMATIC_FBP(); ~DIALOG_EDIT_COMPONENT_IN_SCHEMATIC_FBP();
}; };
#endif //__dialog_edit_component_in_schematic_fbp__ #endif //__dialog_edit_component_in_schematic_fbp__
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment