KiCad PCB EDA Suite
DIALOG_SCRIPTING_BASE Class Reference

Class DIALOG_SCRIPTING_BASE. More...

#include <dialog_scripting_base.h>

Inheritance diagram for DIALOG_SCRIPTING_BASE:
DIALOG_SCRIPTING

Public Member Functions

 DIALOG_SCRIPTING_BASE (wxWindow *parent, wxWindowID id=wxID_ANY, const wxString &title=wxT("Scripting Test Window"), const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxSize(500, 468), long style=wxDEFAULT_FRAME_STYLE|wxTAB_TRAVERSAL)
 
 ~DIALOG_SCRIPTING_BASE ()
 

Protected Member Functions

virtual void OnRunButtonClick (wxCommandEvent &event)
 

Protected Attributes

wxTextCtrl * m_txScript
 
wxButton * m_btRun
 

Detailed Description

Class DIALOG_SCRIPTING_BASE.

Definition at line 29 of file dialog_scripting_base.h.

Constructor & Destructor Documentation

DIALOG_SCRIPTING_BASE::DIALOG_SCRIPTING_BASE ( wxWindow *  parent,
wxWindowID  id = wxID_ANY,
const wxString &  title = wxT("Scripting Test Window"),
const wxPoint pos = wxDefaultPosition,
const wxSize &  size = wxSize( 500,468 ),
long  style = wxDEFAULT_FRAME_STYLE|wxTAB_TRAVERSAL 
)

Definition at line 12 of file dialog_scripting_base.cpp.

References m_btRun, m_txScript, and OnRunButtonClick().

12  : wxFrame( parent, id, title, pos, size, style )
13 {
14  this->SetSizeHints( wxDefaultSize, wxDefaultSize );
15 
16  wxBoxSizer* bSizerMain;
17  bSizerMain = new wxBoxSizer( wxVERTICAL );
18 
19  m_txScript = new wxTextCtrl( this, wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, wxHSCROLL|wxTE_MULTILINE );
20  m_txScript->SetMaxLength( 0 );
21  m_txScript->SetMinSize( wxSize( 480,500 ) );
22 
23  bSizerMain->Add( m_txScript, 1, wxALL|wxEXPAND, 5 );
24 
25  m_btRun = new wxButton( this, wxID_ANY, wxT("&Run"), wxDefaultPosition, wxDefaultSize, 0 );
26  bSizerMain->Add( m_btRun, 0, wxALL, 5 );
27 
28 
29  this->SetSizer( bSizerMain );
30  this->Layout();
31 
32  this->Centre( wxBOTH );
33 
34  // Connect Events
35  m_btRun->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_SCRIPTING_BASE::OnRunButtonClick ), NULL, this );
36 }
virtual void OnRunButtonClick(wxCommandEvent &event)
DIALOG_SCRIPTING_BASE::~DIALOG_SCRIPTING_BASE ( )

Definition at line 38 of file dialog_scripting_base.cpp.

References m_btRun, and OnRunButtonClick().

39 {
40  // Disconnect Events
41  m_btRun->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_SCRIPTING_BASE::OnRunButtonClick ), NULL, this );
42 
43 }
virtual void OnRunButtonClick(wxCommandEvent &event)

Member Function Documentation

virtual void DIALOG_SCRIPTING_BASE::OnRunButtonClick ( wxCommandEvent &  event)
inlineprotectedvirtual

Reimplemented in DIALOG_SCRIPTING.

Definition at line 38 of file dialog_scripting_base.h.

Referenced by DIALOG_SCRIPTING_BASE(), and ~DIALOG_SCRIPTING_BASE().

38 { event.Skip(); }

Member Data Documentation

wxButton* DIALOG_SCRIPTING_BASE::m_btRun
protected

Definition at line 35 of file dialog_scripting_base.h.

Referenced by DIALOG_SCRIPTING_BASE(), and ~DIALOG_SCRIPTING_BASE().

wxTextCtrl* DIALOG_SCRIPTING_BASE::m_txScript
protected

The documentation for this class was generated from the following files: