Commit 00d253de authored by dickelbeck's avatar dickelbeck
Browse files

ESC finally works

parent 7f9af0fd
Loading
Loading
Loading
Loading
+56 −45
Original line number Original line Diff line number Diff line
@@ -69,19 +69,19 @@ BEGIN_EVENT_TABLE( dialog_freeroute_exchange, wxDialog )
    EVT_INIT_DIALOG( dialog_freeroute_exchange::OnInitDialog )
    EVT_INIT_DIALOG( dialog_freeroute_exchange::OnInitDialog )
    EVT_CLOSE( dialog_freeroute_exchange::OnCloseWindow )
    EVT_CLOSE( dialog_freeroute_exchange::OnCloseWindow )


    EVT_BUTTON( ID_CREATE_EXPORT_DSN_FILE, dialog_freeroute_exchange::OnCreateExportDsnFileClick )
    EVT_BUTTON( ID_BUTTON4, dialog_freeroute_exchange::OnButton4Click )


    EVT_BUTTON( ID_RUN_FREEROUTE, dialog_freeroute_exchange::OnRunFreerouteClick )
    EVT_BUTTON( ID_BUTTON5, dialog_freeroute_exchange::OnButton5Click )


    EVT_BUTTON( ID_IMPORT_FREEROUTE_DSN_FILE, dialog_freeroute_exchange::OnImportFreerouteDsnFileClick )
    EVT_BUTTON( ID_BUTTON6, dialog_freeroute_exchange::OnButton6Click )


    EVT_BUTTON( wxID_CANCEL, dialog_freeroute_exchange::OnCancelClick )
    EVT_BUTTON( ID_BUTTON7, dialog_freeroute_exchange::OnButton7Click )


    EVT_BUTTON( ID_GOTO_FREEROUTE_WEB_SITE, dialog_freeroute_exchange::OnGotoFreerouteWebSiteClick )
    EVT_TEXT( ID_TEXTCTRL2, dialog_freeroute_exchange::OnTextEditFrUrlUpdated )


    EVT_TEXT( ID_TEXT_EDIT_FR_URL, dialog_freeroute_exchange::OnTextEditFrUrlUpdated )
    EVT_TEXT( ID_TEXTCTRL3, dialog_freeroute_exchange::OnTextEditFrCmdUpdated )


    EVT_TEXT( ID_TEXT_EDIT_FR_CMD, dialog_freeroute_exchange::OnTextEditFrCmdUpdated )
    EVT_BUTTON( wxID_CANCEL, dialog_freeroute_exchange::OnCancelClick )


////@end dialog_freeroute_exchange event table entries
////@end dialog_freeroute_exchange event table entries


@@ -156,6 +156,7 @@ void dialog_freeroute_exchange::Init()
{
{
////@begin dialog_freeroute_exchange member initialisation
////@begin dialog_freeroute_exchange member initialisation
    m_FreeRouteSetupChanged = false;
    m_FreeRouteSetupChanged = false;
    m_ExportDSN = NULL;
    m_FreerouteURLName = NULL;
    m_FreerouteURLName = NULL;
    m_FreerouteURLCommandString = NULL;
    m_FreerouteURLCommandString = NULL;
////@end dialog_freeroute_exchange member initialisation
////@end dialog_freeroute_exchange member initialisation
@@ -169,63 +170,70 @@ void dialog_freeroute_exchange::Init()
void dialog_freeroute_exchange::CreateControls()
void dialog_freeroute_exchange::CreateControls()
{
{
////@begin dialog_freeroute_exchange content construction
////@begin dialog_freeroute_exchange content construction
    // Generated by DialogBlocks, Wed 19 Mar 2008 00:26:30 CDT (unregistered)
    // Generated by DialogBlocks, Wed 19 Mar 2008 09:36:35 CDT (unregistered)


    dialog_freeroute_exchange* itemDialog1 = this;
    dialog_freeroute_exchange* itemDialog1 = this;


    wxBoxSizer* itemBoxSizer2 = new wxBoxSizer(wxHORIZONTAL);
    wxBoxSizer* itemBoxSizer2 = new wxBoxSizer(wxVERTICAL);
    itemDialog1->SetSizer(itemBoxSizer2);
    itemDialog1->SetSizer(itemBoxSizer2);


    wxBoxSizer* itemBoxSizer3 = new wxBoxSizer(wxVERTICAL);
    wxPanel* itemPanel3 = new wxPanel( itemDialog1, ID_PANEL1, wxDefaultPosition, wxDefaultSize, wxRAISED_BORDER|wxTAB_TRAVERSAL );
    itemBoxSizer2->Add(itemBoxSizer3, 0, wxGROW|wxALL, 5);
    itemBoxSizer2->Add(itemPanel3, 0, wxALIGN_CENTER_HORIZONTAL|wxALL, 5);


    wxButton* itemButton4 = new wxButton( itemDialog1, ID_CREATE_EXPORT_DSN_FILE, _("Export a Specctra Design (*.dsn) File"), wxDefaultPosition, wxDefaultSize, 0 );
    wxBoxSizer* itemBoxSizer4 = new wxBoxSizer(wxHORIZONTAL);
    if (dialog_freeroute_exchange::ShowToolTips())
    itemPanel3->SetSizer(itemBoxSizer4);
        itemButton4->SetToolTip(_("Export a Specctra DSN file (to FreeRouter)"));
    itemBoxSizer3->Add(itemButton4, 0, wxGROW|wxALL, 5);


    wxButton* itemButton5 = new wxButton( itemDialog1, ID_RUN_FREEROUTE, _("Launch FreeRouter via Browser"), wxDefaultPosition, wxDefaultSize, 0 );
    wxStaticBox* itemStaticBoxSizer5Static = new wxStaticBox(itemPanel3, wxID_ANY, _T(""));
    if (dialog_freeroute_exchange::ShowToolTips())
    wxStaticBoxSizer* itemStaticBoxSizer5 = new wxStaticBoxSizer(itemStaticBoxSizer5Static, wxVERTICAL);
        itemButton5->SetToolTip(_("User your browser's Java Web Start function to run FreeRouter via Internet"));
    itemBoxSizer4->Add(itemStaticBoxSizer5, 0, wxGROW|wxALL, 5);
    itemBoxSizer3->Add(itemButton5, 0, wxGROW|wxALL, 5);


    wxButton* itemButton6 = new wxButton( itemDialog1, ID_IMPORT_FREEROUTE_DSN_FILE, _("Back Import the Specctra Session (*.ses) File"), wxDefaultPosition, wxDefaultSize, 0 );
    m_ExportDSN = new wxButton( itemPanel3, ID_BUTTON4, _("Export a Specctra Design (*.dsn) File"), wxDefaultPosition, wxDefaultSize, 0 );
    if (dialog_freeroute_exchange::ShowToolTips())
    if (dialog_freeroute_exchange::ShowToolTips())
        itemButton6->SetToolTip(_("Merge a session file created by FreeRouter with the current board."));
        m_ExportDSN->SetToolTip(_("Export a Specctra DSN file (to FreeRouter)"));
    itemBoxSizer3->Add(itemButton6, 0, wxGROW|wxALL, 5);
    itemStaticBoxSizer5->Add(m_ExportDSN, 0, wxGROW|wxALL, 5);

    wxStdDialogButtonSizer* itemStdDialogButtonSizer7 = new wxStdDialogButtonSizer;


    itemBoxSizer3->Add(itemStdDialogButtonSizer7, 0, wxGROW|wxALL, 5);
    wxButton* itemButton7 = new wxButton( itemPanel3, ID_BUTTON5, _("Launch FreeRouter via Browser"), wxDefaultPosition, wxDefaultSize, 0 );
    wxButton* itemButton8 = new wxButton( itemDialog1, wxID_CANCEL, _("&Close"), wxDefaultPosition, wxDefaultSize, 0 );
    if (dialog_freeroute_exchange::ShowToolTips())
    itemButton8->SetDefault();
        itemButton7->SetToolTip(_("User your browser's Java Web Start function to run FreeRouter via Internet"));
    itemStdDialogButtonSizer7->AddButton(itemButton8);
    itemStaticBoxSizer5->Add(itemButton7, 0, wxGROW|wxALL, 5);


    itemStdDialogButtonSizer7->Realize();
    wxButton* itemButton8 = new wxButton( itemPanel3, ID_BUTTON6, _("Back Import the Specctra Session (*.ses) File"), wxDefaultPosition, wxDefaultSize, 0 );
    if (dialog_freeroute_exchange::ShowToolTips())
        itemButton8->SetToolTip(_("Merge a session file created by FreeRouter with the current board."));
    itemStaticBoxSizer5->Add(itemButton8, 0, wxGROW|wxALL, 5);


    wxBoxSizer* itemBoxSizer9 = new wxBoxSizer(wxVERTICAL);
    wxStaticBox* itemStaticBoxSizer9Static = new wxStaticBox(itemPanel3, wxID_ANY, _T(""));
    itemBoxSizer2->Add(itemBoxSizer9, 1, wxGROW|wxALL, 5);
    wxStaticBoxSizer* itemStaticBoxSizer9 = new wxStaticBoxSizer(itemStaticBoxSizer9Static, wxVERTICAL);
    itemBoxSizer4->Add(itemStaticBoxSizer9, 1, wxGROW|wxALL, 5);


    wxButton* itemButton10 = new wxButton( itemDialog1, ID_GOTO_FREEROUTE_WEB_SITE, _("Visit the FreeRouting.net Website with your Browser"), wxDefaultPosition, wxDefaultSize, 0 );
    wxButton* itemButton10 = new wxButton( itemPanel3, ID_BUTTON7, _("Visit the FreeRouting.net Website with your Browser"), wxDefaultPosition, wxDefaultSize, 0 );
    if (dialog_freeroute_exchange::ShowToolTips())
    if (dialog_freeroute_exchange::ShowToolTips())
        itemButton10->SetToolTip(_("Launch your browser and go to the FreeRouting.net website"));
        itemButton10->SetToolTip(_("Launch your browser and go to the FreeRouting.net website"));
    itemBoxSizer9->Add(itemButton10, 0, wxGROW|wxALL, 5);
    itemStaticBoxSizer9->Add(itemButton10, 0, wxGROW|wxALL, 5);


    wxStaticText* itemStaticText11 = new wxStaticText( itemDialog1, wxID_STATIC, _("FreeRouting.net URL"), wxDefaultPosition, wxDefaultSize, 0 );
    wxStaticText* itemStaticText11 = new wxStaticText( itemPanel3, wxID_STATIC, _("FreeRouting.net URL"), wxDefaultPosition, wxDefaultSize, 0 );
    itemBoxSizer9->Add(itemStaticText11, 0, wxGROW|wxLEFT|wxRIGHT|wxTOP, 5);
    itemStaticBoxSizer9->Add(itemStaticText11, 0, wxGROW|wxLEFT|wxRIGHT|wxTOP, 5);


    m_FreerouteURLName = new wxTextCtrl( itemDialog1, ID_TEXT_EDIT_FR_URL, _T(""), wxDefaultPosition, wxDefaultSize, 0 );
    m_FreerouteURLName = new wxTextCtrl( itemPanel3, ID_TEXTCTRL2, _T(""), wxDefaultPosition, wxDefaultSize, 0 );
    if (dialog_freeroute_exchange::ShowToolTips())
    if (dialog_freeroute_exchange::ShowToolTips())
        m_FreerouteURLName->SetToolTip(_("The URL of the FreeRouting.net website"));
        m_FreerouteURLName->SetToolTip(_("The URL of the FreeRouting.net website"));
    itemBoxSizer9->Add(m_FreerouteURLName, 1, wxGROW|wxLEFT|wxRIGHT|wxBOTTOM, 5);
    itemStaticBoxSizer9->Add(m_FreerouteURLName, 1, wxGROW|wxLEFT|wxRIGHT|wxBOTTOM, 5);


    wxStaticText* itemStaticText13 = new wxStaticText( itemDialog1, wxID_STATIC, _("FreeRouting.net Command"), wxDefaultPosition, wxDefaultSize, 0 );
    wxStaticText* itemStaticText13 = new wxStaticText( itemPanel3, wxID_STATIC, _("FreeRouting.net Command"), wxDefaultPosition, wxDefaultSize, 0 );
    itemBoxSizer9->Add(itemStaticText13, 0, wxGROW|wxLEFT|wxRIGHT|wxTOP, 5);
    itemStaticBoxSizer9->Add(itemStaticText13, 0, wxGROW|wxLEFT|wxRIGHT|wxTOP, 5);


    m_FreerouteURLCommandString = new wxTextCtrl( itemDialog1, ID_TEXT_EDIT_FR_CMD, _T(""), wxDefaultPosition, wxDefaultSize, 0 );
    m_FreerouteURLCommandString = new wxTextCtrl( itemPanel3, ID_TEXTCTRL3, _T(""), wxDefaultPosition, wxDefaultSize, 0 );
    if (dialog_freeroute_exchange::ShowToolTips())
    if (dialog_freeroute_exchange::ShowToolTips())
        m_FreerouteURLCommandString->SetToolTip(_("The URL of the JNLP file which Java Web Start uses to launch the FreeRouter"));
        m_FreerouteURLCommandString->SetToolTip(_("The URL of the JNLP file which Java Web Start uses to launch the FreeRouter"));
    itemBoxSizer9->Add(m_FreerouteURLCommandString, 1, wxGROW|wxLEFT|wxRIGHT|wxBOTTOM, 5);
    itemStaticBoxSizer9->Add(m_FreerouteURLCommandString, 1, wxGROW|wxLEFT|wxRIGHT|wxBOTTOM, 5);

    wxStdDialogButtonSizer* itemStdDialogButtonSizer15 = new wxStdDialogButtonSizer;

    itemBoxSizer2->Add(itemStdDialogButtonSizer15, 0, wxGROW|wxALL, 5);
    wxButton* itemButton16 = new wxButton( itemDialog1, wxID_CANCEL, _("&Close"), wxDefaultPosition, wxDefaultSize, 0 );
    itemStdDialogButtonSizer15->AddButton(itemButton16);

    itemStdDialogButtonSizer15->Realize();


////@end dialog_freeroute_exchange content construction
////@end dialog_freeroute_exchange content construction


@@ -287,7 +295,7 @@ wxIcon dialog_freeroute_exchange::GetIconResource( const wxString& name )
 * wxEVT_COMMAND_BUTTON_CLICKED event handler for ID_CREATE_EXPORT_DSN_FILE
 * wxEVT_COMMAND_BUTTON_CLICKED event handler for ID_CREATE_EXPORT_DSN_FILE
 */
 */


void dialog_freeroute_exchange::OnCreateExportDsnFileClick( wxCommandEvent& event )
void dialog_freeroute_exchange::OnButton4Click( wxCommandEvent& event )
{
{
    m_Parent->ExportToSpecctra( event );
    m_Parent->ExportToSpecctra( event );
}
}
@@ -297,7 +305,7 @@ void dialog_freeroute_exchange::OnCreateExportDsnFileClick( wxCommandEvent& even
 * wxEVT_COMMAND_BUTTON_CLICKED event handler for ID_IMPORT_FREEROUTE_DSN_FILE
 * wxEVT_COMMAND_BUTTON_CLICKED event handler for ID_IMPORT_FREEROUTE_DSN_FILE
 */
 */


void dialog_freeroute_exchange::OnImportFreerouteDsnFileClick( wxCommandEvent& event )
void dialog_freeroute_exchange::OnButton6Click( wxCommandEvent& event )
{
{
    m_Parent->ImportSpecctraSession(  event );
    m_Parent->ImportSpecctraSession(  event );
}
}
@@ -307,7 +315,7 @@ void dialog_freeroute_exchange::OnImportFreerouteDsnFileClick( wxCommandEvent& e
 * wxEVT_COMMAND_BUTTON_CLICKED event handler for ID_RUN_FREEROUTE
 * wxEVT_COMMAND_BUTTON_CLICKED event handler for ID_RUN_FREEROUTE
 */
 */


void dialog_freeroute_exchange::OnRunFreerouteClick( wxCommandEvent& event )
void dialog_freeroute_exchange::OnButton5Click( wxCommandEvent& event )
{
{
    wxString command = m_FreerouteURLCommandString->GetValue();
    wxString command = m_FreerouteURLCommandString->GetValue();


@@ -324,7 +332,7 @@ void dialog_freeroute_exchange::OnRunFreerouteClick( wxCommandEvent& event )
 * wxEVT_COMMAND_BUTTON_CLICKED event handler for ID_BUTTON
 * wxEVT_COMMAND_BUTTON_CLICKED event handler for ID_BUTTON
 */
 */


void dialog_freeroute_exchange::OnGotoFreerouteWebSiteClick( wxCommandEvent& event )
void dialog_freeroute_exchange::OnButton7Click( wxCommandEvent& event )
{
{
    wxString command = m_FreerouteURLName->GetValue();
    wxString command = m_FreerouteURLName->GetValue();


@@ -389,6 +397,9 @@ void dialog_freeroute_exchange::OnTextEditFrCmdUpdated( wxCommandEvent& event )


void dialog_freeroute_exchange::OnInitDialog( wxInitDialogEvent& event )
void dialog_freeroute_exchange::OnInitDialog( wxInitDialogEvent& event )
{
{
    m_ExportDSN->SetFocus();


////@begin wxEVT_INIT_DIALOG event handler for ID_DIALOG_FREEROUTE_EXCHANGE in dialog_freeroute_exchange.
////@begin wxEVT_INIT_DIALOG event handler for ID_DIALOG_FREEROUTE_EXCHANGE in dialog_freeroute_exchange.
    // Before editing this code, remove the block markers.
    // Before editing this code, remove the block markers.
    event.Skip();
    event.Skip();
+21 −19
Original line number Original line Diff line number Diff line
@@ -36,12 +36,13 @@


////@begin control identifiers
////@begin control identifiers
#define ID_DIALOG_FREEROUTE_EXCHANGE 10000
#define ID_DIALOG_FREEROUTE_EXCHANGE 10000
#define ID_CREATE_EXPORT_DSN_FILE 10001
#define ID_PANEL1 10001
#define ID_RUN_FREEROUTE 10002
#define ID_BUTTON4 10002
#define ID_IMPORT_FREEROUTE_DSN_FILE 10003
#define ID_BUTTON5 10003
#define ID_GOTO_FREEROUTE_WEB_SITE 10004
#define ID_BUTTON6 10004
#define ID_TEXT_EDIT_FR_URL 10005
#define ID_BUTTON7 10005
#define ID_TEXT_EDIT_FR_CMD 10006
#define ID_TEXTCTRL2 10006
#define ID_TEXTCTRL3 10013
#define SYMBOL_DIALOG_FREEROUTE_EXCHANGE_STYLE wxCAPTION|wxRESIZE_BORDER|wxCLOSE_BOX|wxTAB_TRAVERSAL
#define SYMBOL_DIALOG_FREEROUTE_EXCHANGE_STYLE wxCAPTION|wxRESIZE_BORDER|wxCLOSE_BOX|wxTAB_TRAVERSAL
#define SYMBOL_DIALOG_FREEROUTE_EXCHANGE_TITLE _("dialog_freeroute_exchange")
#define SYMBOL_DIALOG_FREEROUTE_EXCHANGE_TITLE _("dialog_freeroute_exchange")
#define SYMBOL_DIALOG_FREEROUTE_EXCHANGE_IDNAME ID_DIALOG_FREEROUTE_EXCHANGE
#define SYMBOL_DIALOG_FREEROUTE_EXCHANGE_IDNAME ID_DIALOG_FREEROUTE_EXCHANGE
@@ -84,27 +85,27 @@ public:
    /// wxEVT_CLOSE_WINDOW event handler for ID_DIALOG_FREEROUTE_EXCHANGE
    /// wxEVT_CLOSE_WINDOW event handler for ID_DIALOG_FREEROUTE_EXCHANGE
    void OnCloseWindow( wxCloseEvent& event );
    void OnCloseWindow( wxCloseEvent& event );


    /// wxEVT_COMMAND_BUTTON_CLICKED event handler for ID_CREATE_EXPORT_DSN_FILE
    /// wxEVT_COMMAND_BUTTON_CLICKED event handler for ID_BUTTON4
    void OnCreateExportDsnFileClick( wxCommandEvent& event );
    void OnButton4Click( wxCommandEvent& event );


    /// wxEVT_COMMAND_BUTTON_CLICKED event handler for ID_RUN_FREEROUTE
    /// wxEVT_COMMAND_BUTTON_CLICKED event handler for ID_BUTTON5
    void OnRunFreerouteClick( wxCommandEvent& event );
    void OnButton5Click( wxCommandEvent& event );


    /// wxEVT_COMMAND_BUTTON_CLICKED event handler for ID_IMPORT_FREEROUTE_DSN_FILE
    /// wxEVT_COMMAND_BUTTON_CLICKED event handler for ID_BUTTON6
    void OnImportFreerouteDsnFileClick( wxCommandEvent& event );
    void OnButton6Click( wxCommandEvent& event );


    /// wxEVT_COMMAND_BUTTON_CLICKED event handler for wxID_CANCEL
    /// wxEVT_COMMAND_BUTTON_CLICKED event handler for ID_BUTTON7
    void OnCancelClick( wxCommandEvent& event );
    void OnButton7Click( wxCommandEvent& event );

    /// wxEVT_COMMAND_BUTTON_CLICKED event handler for ID_GOTO_FREEROUTE_WEB_SITE
    void OnGotoFreerouteWebSiteClick( wxCommandEvent& event );


    /// wxEVT_COMMAND_TEXT_UPDATED event handler for ID_TEXT_EDIT_FR_URL
    /// wxEVT_COMMAND_TEXT_UPDATED event handler for ID_TEXTCTRL2
    void OnTextEditFrUrlUpdated( wxCommandEvent& event );
    void OnTextEditFrUrlUpdated( wxCommandEvent& event );


    /// wxEVT_COMMAND_TEXT_UPDATED event handler for ID_TEXT_EDIT_FR_CMD
    /// wxEVT_COMMAND_TEXT_UPDATED event handler for ID_TEXTCTRL3
    void OnTextEditFrCmdUpdated( wxCommandEvent& event );
    void OnTextEditFrCmdUpdated( wxCommandEvent& event );


    /// wxEVT_COMMAND_BUTTON_CLICKED event handler for wxID_CANCEL
    void OnCancelClick( wxCommandEvent& event );

////@end dialog_freeroute_exchange event handler declarations
////@end dialog_freeroute_exchange event handler declarations


////@begin dialog_freeroute_exchange member function declarations
////@begin dialog_freeroute_exchange member function declarations
@@ -123,6 +124,7 @@ public:
    static bool ShowToolTips();
    static bool ShowToolTips();


////@begin dialog_freeroute_exchange member variables
////@begin dialog_freeroute_exchange member variables
    wxButton* m_ExportDSN;
    wxTextCtrl* m_FreerouteURLName;
    wxTextCtrl* m_FreerouteURLName;
    wxTextCtrl* m_FreerouteURLCommandString;
    wxTextCtrl* m_FreerouteURLCommandString;
private:
private:
+708 −589

File changed.

Preview size limit exceeded, changes collapsed.