2007-06-05 12:10:51 +00:00
|
|
|
/////////////////////////////////////////////////////////////////////////////
|
|
|
|
// Name: dialog_erc.h
|
|
|
|
// Author: jean-pierre Charras
|
2009-07-05 12:09:41 +00:00
|
|
|
// Licence: GPL
|
2007-06-05 12:10:51 +00:00
|
|
|
/////////////////////////////////////////////////////////////////////////////
|
|
|
|
|
|
|
|
#ifndef _DIALOG_ERC_H_
|
|
|
|
#define _DIALOG_ERC_H_
|
|
|
|
|
2009-07-08 15:42:45 +00:00
|
|
|
#include <wx/htmllbox.h>
|
|
|
|
#include <vector>
|
|
|
|
|
|
|
|
|
2012-01-23 04:33:36 +00:00
|
|
|
#include <dialog_erc_base.h>
|
2007-06-05 12:10:51 +00:00
|
|
|
|
|
|
|
/* Variable locales */
|
2009-07-08 15:42:45 +00:00
|
|
|
extern int DiagErc[PIN_NMAX][PIN_NMAX];
|
2012-01-22 17:20:22 +00:00
|
|
|
extern bool DiagErcTableInit; // go to true after DiagErc init
|
2009-07-08 15:42:45 +00:00
|
|
|
extern int DefaultDiagErc[PIN_NMAX][PIN_NMAX];
|
2009-07-03 18:25:06 +00:00
|
|
|
extern const wxChar* CommentERC_H[];
|
|
|
|
extern const wxChar* CommentERC_V[];
|
2007-06-05 12:10:51 +00:00
|
|
|
|
2009-07-03 18:25:06 +00:00
|
|
|
/* Control identifiers */
|
2007-06-05 12:10:51 +00:00
|
|
|
#define ID_MATRIX_0 1800
|
|
|
|
|
|
|
|
/*!
|
2009-07-03 18:25:06 +00:00
|
|
|
* DIALOG_ERC class declaration
|
2007-06-05 12:10:51 +00:00
|
|
|
*/
|
|
|
|
|
2009-07-08 15:42:45 +00:00
|
|
|
class DIALOG_ERC : public DIALOG_ERC_BASE
|
2009-07-05 12:09:41 +00:00
|
|
|
{
|
2009-07-08 15:42:45 +00:00
|
|
|
DECLARE_EVENT_TABLE()
|
2009-07-03 18:25:06 +00:00
|
|
|
|
|
|
|
private:
|
2010-12-08 20:12:46 +00:00
|
|
|
SCH_EDIT_FRAME* m_Parent;
|
|
|
|
wxBitmapButton* m_ButtonList[PIN_NMAX][PIN_NMAX];
|
|
|
|
bool m_Initialized;
|
|
|
|
static bool m_writeErcFile;
|
2007-06-05 12:10:51 +00:00
|
|
|
|
|
|
|
public:
|
2009-07-08 15:42:45 +00:00
|
|
|
|
2007-06-05 12:10:51 +00:00
|
|
|
/// Constructors
|
2010-12-08 20:12:46 +00:00
|
|
|
DIALOG_ERC( SCH_EDIT_FRAME* parent );
|
2007-06-05 12:10:51 +00:00
|
|
|
|
2009-07-03 18:25:06 +00:00
|
|
|
void Init();
|
2007-06-05 12:10:51 +00:00
|
|
|
|
|
|
|
/// wxEVT_COMMAND_BUTTON_CLICKED event handler for ID_ERC_CMP
|
|
|
|
void OnErcCmpClick( wxCommandEvent& event );
|
|
|
|
|
|
|
|
/// wxEVT_COMMAND_BUTTON_CLICKED event handler for ID_ERASE_DRC_MARKERS
|
|
|
|
void OnEraseDrcMarkersClick( wxCommandEvent& event );
|
|
|
|
|
2007-11-07 04:24:25 +00:00
|
|
|
/// wxEVT_COMMAND_BUTTON_CLICKED event handler for wxID_CANCEL
|
|
|
|
void OnCancelClick( wxCommandEvent& event );
|
2007-06-05 12:10:51 +00:00
|
|
|
|
|
|
|
/// wxEVT_COMMAND_BUTTON_CLICKED event handler for ID_RESET_MATRIX
|
|
|
|
void OnResetMatrixClick( wxCommandEvent& event );
|
|
|
|
|
2009-07-08 15:42:45 +00:00
|
|
|
// Double click on a marker info:
|
2012-01-22 17:20:22 +00:00
|
|
|
void OnLeftDClickMarkersList( wxCommandEvent& event );
|
2007-06-05 12:10:51 +00:00
|
|
|
|
2009-07-08 15:42:45 +00:00
|
|
|
void TestErc( wxArrayString* aMessagesList );
|
|
|
|
void DisplayERC_MarkersList();
|
|
|
|
void SelLocal( wxCommandEvent& event );
|
|
|
|
void SelNewCmp( wxCommandEvent& event );
|
|
|
|
void ResetDefaultERCDiag( wxCommandEvent& event );
|
|
|
|
void ChangeErrorLevel( wxCommandEvent& event );
|
|
|
|
void ReBuildMatrixPanel();
|
2007-06-05 12:10:51 +00:00
|
|
|
};
|
|
|
|
|
2009-07-08 15:42:45 +00:00
|
|
|
|
2007-06-05 12:10:51 +00:00
|
|
|
#endif
|
2009-07-08 15:42:45 +00:00
|
|
|
|
|
|
|
// _DIALOG_ERC_H_
|