/////////////////////////////////////////////////////////////////////////////
// Name:        dialog_netlist.h
// Purpose:     
// Author:      jean-pierre Charras
// Modified by: 
// Created:     26/02/2006 17:42:19
// RCS-ID:      
// Copyright:   License GNU
// Licence:     
/////////////////////////////////////////////////////////////////////////////

// Generated by DialogBlocks (unregistered), 26/02/2006 17:42:19

#ifndef _DIALOG_NETLIST_H_
#define _DIALOG_NETLIST_H_


/*!
 * Includes
 */

////@begin includes
#include "wx/valgen.h"
////@end includes

/*!
 * Forward declarations
 */

////@begin forward declarations
////@end forward declarations

/*!
 * Control identifiers
 */

////@begin control identifiers
#define ID_DIALOG 10000
#define SYMBOL_WINEDA_NETLISTFRAME_STYLE wxCAPTION|wxRESIZE_BORDER|wxSYSTEM_MENU|wxCLOSE_BOX
#define SYMBOL_WINEDA_NETLISTFRAME_TITLE _("Netlist: ")
#define SYMBOL_WINEDA_NETLISTFRAME_IDNAME ID_DIALOG
#define SYMBOL_WINEDA_NETLISTFRAME_SIZE wxSize(400, 300)
#define SYMBOL_WINEDA_NETLISTFRAME_POSITION wxDefaultPosition
#define ID_RADIOBOX 10005
#define ID_RADIOBOX1 10006
#define ID_RADIOBOX2 10007
#define ID_CHECKBOX 10008
#define ID_OPEN_NELIST 10001
#define ID_READ_NETLIST_FILE 10002
#define ID_TEST_NETLIST 10003
#define ID_COMPILE_RATSNEST 10004
#define ID_TEXTCTRL 10009
////@end control identifiers

/*!
 * Compatibility
 */

#ifndef wxCLOSE_BOX
#define wxCLOSE_BOX 0x1000
#endif

/*!
 * WinEDA_NetlistFrame class declaration
 */

class WinEDA_NetlistFrame: public wxDialog
{    
    DECLARE_DYNAMIC_CLASS( WinEDA_NetlistFrame )
    DECLARE_EVENT_TABLE()

public:
    /// Constructors
    WinEDA_NetlistFrame( );
    WinEDA_NetlistFrame( WinEDA_PcbFrame* parent,wxDC * DC, 
        wxWindowID id = SYMBOL_WINEDA_NETLISTFRAME_IDNAME, const wxString& caption = SYMBOL_WINEDA_NETLISTFRAME_TITLE, const wxPoint& pos = SYMBOL_WINEDA_NETLISTFRAME_POSITION, const wxSize& size = SYMBOL_WINEDA_NETLISTFRAME_SIZE, long style = SYMBOL_WINEDA_NETLISTFRAME_STYLE );

    /// Creation
    bool Create( wxWindow* parent, wxWindowID id = SYMBOL_WINEDA_NETLISTFRAME_IDNAME, const wxString& caption = SYMBOL_WINEDA_NETLISTFRAME_TITLE, const wxPoint& pos = SYMBOL_WINEDA_NETLISTFRAME_POSITION, const wxSize& size = SYMBOL_WINEDA_NETLISTFRAME_SIZE, long style = SYMBOL_WINEDA_NETLISTFRAME_STYLE );

    /// Creates the controls and sizers
    void CreateControls();

////@begin WinEDA_NetlistFrame event handler declarations

    /// wxEVT_COMMAND_BUTTON_CLICKED event handler for ID_OPEN_NELIST
    void OnOpenNelistClick( wxCommandEvent& event );

    /// wxEVT_COMMAND_BUTTON_CLICKED event handler for ID_READ_NETLIST_FILE
    void OnReadNetlistFileClick( wxCommandEvent& event );

    /// wxEVT_COMMAND_BUTTON_CLICKED event handler for ID_TEST_NETLIST
    void OnTestNetlistClick( wxCommandEvent& event );

    /// wxEVT_COMMAND_BUTTON_CLICKED event handler for ID_COMPILE_RATSNEST
    void OnCompileRatsnestClick( wxCommandEvent& event );

    /// wxEVT_COMMAND_BUTTON_CLICKED event handler for wxID_CLOSE
    void OnCloseClick( wxCommandEvent& event );

////@end WinEDA_NetlistFrame event handler declarations

////@begin WinEDA_NetlistFrame member function declarations

    /// Retrieves bitmap resources
    wxBitmap GetBitmapResource( const wxString& name );

    /// Retrieves icon resources
    wxIcon GetIconResource( const wxString& name );
////@end WinEDA_NetlistFrame member function declarations

    /// Should we show tooltips?
    static bool ShowToolTips();

	void ReadPcbNetlist(wxCommandEvent& event);
	void Set_NetlisteName(wxCommandEvent& event);
	bool OpenNetlistFile(wxCommandEvent& event);
	int BuildListeNetModules(wxCommandEvent& event, wxArrayString & BufName);
	void ModulesControle(wxCommandEvent& event);
	int ReadListeModules(const wxString * RefCmp, long TimeStamp, wxString & NameModule);
	int SetPadNetName( char * Line, MODULE * Module);
	MODULE * ReadNetModule( char * Text,
						int * UseFichCmp, int TstOnly);
	void AddToList(const wxString & NameLibCmp, const wxString & NameCmp,int TimeStamp );
	void LoadListeModules(wxDC *DC);

////@begin WinEDA_NetlistFrame member variables
    wxRadioBox* m_Select_By_Timestamp;
    wxRadioBox* m_DeleteBadTracks;
    wxRadioBox* m_ChangeExistantModuleCtrl;
    wxCheckBox* m_DisplayWarningCtrl;
    wxTextCtrl* m_MessageWindow;
////@end WinEDA_NetlistFrame member variables
	WinEDA_PcbFrame * m_Parent;
	wxDC * m_DC;
};

#endif
    // _DIALOG_NETLIST_H_
