// Berkeley Open Infrastructure for Network Computing // http://boinc.berkeley.edu // Copyright (C) 2005 University of California // // This is free software; you can redistribute it and/or // modify it under the terms of the GNU Lesser General Public // License as published by the Free Software Foundation; // either version 2.1 of the License, or (at your option) any later version. // // This software is distributed in the hope that it will be useful, // but WITHOUT ANY WARRANTY; without even the implied warranty of // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. // See the GNU Lesser General Public License for more details. // // To view the GNU Lesser General Public License visit // http://www.gnu.org/copyleft/lesser.html // or write to the Free Software Foundation, Inc., // 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA // #if defined(__GNUG__) && !defined(__APPLE__) #pragma implementation "DlgConnection.h" #endif // For compilers that support precompilation, includes "wx/wx.h". #include "wx/wxprec.h" #ifdef __BORLANDC__ #pragma hdrstop #endif #ifndef WX_PRECOMP #include "wx/wx.h" #endif ////@begin includes ////@end includes #include "DlgConnection.h" ////@begin XPM images ////@end XPM images /*! * CDlgConnection type definition */ IMPLEMENT_DYNAMIC_CLASS( CDlgConnection, wxDialog ) /*! * CDlgConnection event table definition */ BEGIN_EVENT_TABLE( CDlgConnection, wxDialog ) ////@begin CDlgConnection event table entries ////@end CDlgConnection event table entries END_EVENT_TABLE() /*! * CDlgConnection constructors */ CDlgConnection::CDlgConnection( ) { } CDlgConnection::CDlgConnection( wxWindow* parent, wxWindowID id, const wxString& caption, const wxPoint& pos, const wxSize& size, long style ) { Create(parent, id, caption, pos, size, style); } /*! * CDlgConnection creator */ bool CDlgConnection::Create( wxWindow* parent, wxWindowID id, const wxString& caption, const wxPoint& pos, const wxSize& size, long style ) { ////@begin CDlgConnection member initialisation ////@end CDlgConnection member initialisation ////@begin CDlgConnection creation SetExtraStyle(GetExtraStyle()|wxWS_EX_BLOCK_EVENTS); wxDialog::Create( parent, id, caption, pos, size, style ); CreateControls(); GetSizer()->Fit(this); GetSizer()->SetSizeHints(this); Centre(); ////@end CDlgConnection creation return TRUE; } /*! * Control creation for CDlgConnection */ void CDlgConnection::CreateControls() { ////@begin CDlgConnection content construction CDlgConnection* itemDialog1 = this; wxBoxSizer* itemBoxSizer2 = new wxBoxSizer(wxVERTICAL); itemDialog1->SetSizer(itemBoxSizer2); wxBoxSizer* itemBoxSizer3 = new wxBoxSizer(wxHORIZONTAL); itemBoxSizer2->Add(itemBoxSizer3, 0, wxALIGN_CENTER_HORIZONTAL|wxALL, 5); wxBoxSizer* itemBoxSizer4 = new wxBoxSizer(wxVERTICAL); itemBoxSizer3->Add(itemBoxSizer4, 0, wxALIGN_TOP|wxALL, 5); wxStaticText* itemStaticText5 = new wxStaticText; itemStaticText5->Create( itemDialog1, wxID_STATIC, _("BOINC needs to connect to the network.\nMay it do so now?"), wxDefaultPosition, wxDefaultSize, 0 ); itemBoxSizer4->Add(itemStaticText5, 0, wxALIGN_LEFT|wxALL|wxADJUST_MINSIZE, 5); wxBoxSizer* itemBoxSizer6 = new wxBoxSizer(wxVERTICAL); itemBoxSizer3->Add(itemBoxSizer6, 0, wxALIGN_TOP|wxALL, 5); wxButton* itemButton7 = new wxButton; itemButton7->Create( itemDialog1, wxID_OK, _("&OK"), wxDefaultPosition, wxDefaultSize, 0 ); itemButton7->SetDefault(); itemBoxSizer6->Add(itemButton7, 0, wxALIGN_CENTER_HORIZONTAL|wxALL, 5); wxButton* itemButton8 = new wxButton; itemButton8->Create( itemDialog1, wxID_CANCEL, _("&Cancel"), wxDefaultPosition, wxDefaultSize, 0 ); itemBoxSizer6->Add(itemButton8, 0, wxALIGN_CENTER_HORIZONTAL|wxALL, 5); ////@end CDlgConnection content construction } /*! * Should we show tooltips? */ bool CDlgConnection::ShowToolTips() { return TRUE; } /*! * Get bitmap resources */ wxBitmap CDlgConnection::GetBitmapResource( const wxString& ) { // Bitmap retrieval ////@begin CDlgConnection bitmap retrieval return wxNullBitmap; ////@end CDlgConnection bitmap retrieval } /*! * Get icon resources */ wxIcon CDlgConnection::GetIconResource( const wxString& ) { // Icon retrieval ////@begin CDlgConnection icon retrieval return wxNullIcon; ////@end CDlgConnection icon retrieval }