OpenASIP 2.2
Loading...
Searching...
No Matches
Public Member Functions | Private Types | Private Member Functions | List of all members
ProximAboutDialog Class Reference

#include <ProximAboutDialog.hh>

Inheritance diagram for ProximAboutDialog:
Inheritance graph
Collaboration diagram for ProximAboutDialog:
Collaboration graph

Public Member Functions

 ProximAboutDialog (wxWindow *parent)
 
virtual ~ProximAboutDialog ()
 

Private Types

enum  { ID_TEXT_PROGRAM_NAME = 10000 , ID_TEXT_PROGRAM_VERSION , ID_TEXT_PROGRAM_COPYRIGHT , ID_LINE }
 Widget IDs. More...
 

Private Member Functions

wxSizer * createContents (wxWindow *parent, bool call_fit, bool set_sizer)
 

Detailed Description

About dialog for Proxim.

Definition at line 42 of file ProximAboutDialog.hh.

Member Enumeration Documentation

◆ anonymous enum

anonymous enum
private

Widget IDs.

Enumerator
ID_TEXT_PROGRAM_NAME 
ID_TEXT_PROGRAM_VERSION 
ID_TEXT_PROGRAM_COPYRIGHT 
ID_LINE 

Definition at line 51 of file ProximAboutDialog.hh.

Constructor & Destructor Documentation

◆ ProximAboutDialog()

ProximAboutDialog::ProximAboutDialog ( wxWindow *  parent)

The Constructor.

Parameters
parentParent window of the dialog.

Definition at line 43 of file ProximAboutDialog.cc.

43 :
44 wxDialog(parent, -1, _T("About ") + WxConversion::toWxString(ProximConstants::PROXIM_TITLE), wxDefaultPosition) {
45
46 createContents(this, true, true);
47 dynamic_cast<wxStaticText*>(FindWindow(ID_TEXT_PROGRAM_VERSION))->SetLabel(
48 _T("OpenASIP ") + WxConversion::toWxString(VERSION));
49}
wxSizer * createContents(wxWindow *parent, bool call_fit, bool set_sizer)
static const std::string PROXIM_TITLE
Application title.
static wxString toWxString(const std::string &source)

References createContents(), ID_TEXT_PROGRAM_VERSION, and WxConversion::toWxString().

Here is the call graph for this function:

◆ ~ProximAboutDialog()

ProximAboutDialog::~ProximAboutDialog ( )
virtual

The Destructor.

Definition at line 54 of file ProximAboutDialog.cc.

54 {
55}

Member Function Documentation

◆ createContents()

wxSizer * ProximAboutDialog::createContents ( wxWindow *  parent,
bool  call_fit,
bool  set_sizer 
)
private

Creates contents of the dialog window. Code generated by wxDesigner.

Parameters
parentParent dialog of the contents.
call_fitIf true, fits sizer in dialog window.
set_sizerIf true, sets sizer as dialog's sizer.
Returns
Top level sizer of the contents.

Definition at line 67 of file ProximAboutDialog.cc.

68 {
69
70 wxBoxSizer *item0 = new wxBoxSizer( wxVERTICAL );
71
72 item0->Add( 20, 20, 0, wxALIGN_CENTER|wxALL, 5 );
73
74 wxStaticText *item1 = new wxStaticText( parent, ID_TEXT_PROGRAM_NAME, WxConversion::toWxString(ProximConstants::PROXIM_TITLE), wxDefaultPosition, wxDefaultSize, 0 );
75 item1->SetFont( wxFont( 25, wxROMAN, wxNORMAL, wxNORMAL ) );
76 item0->Add( item1, 0, wxALIGN_CENTER|wxALL, 5 );
77
78 wxStaticText *item2 = new wxStaticText( parent, ID_TEXT_PROGRAM_VERSION, wxT(VERSION), wxDefaultPosition, wxDefaultSize, 0 );
79 item0->Add( item2, 0, wxALIGN_CENTER|wxALL, 5 );
80
81 wxStaticText *item3 = new wxStaticText( parent, ID_TEXT_PROGRAM_COPYRIGHT, ProximConstants::PROXIM_COPYRIGHT, wxDefaultPosition, wxDefaultSize, 0 );
82 item0->Add( item3, 0, wxALIGN_CENTER|wxALL, 5 );
83
84 item0->Add( 20, 20, 0, wxALIGN_CENTER|wxALL, 5 );
85
86 wxStaticLine *item4 = new wxStaticLine( parent, ID_LINE, wxDefaultPosition, wxSize(200,-1), wxLI_HORIZONTAL );
87 item0->Add( item4, 0, wxGROW|wxALL, 5 );
88
89 wxButton *item5 = new wxButton( parent, wxID_OK, wxT("OK"), wxDefaultPosition, wxDefaultSize, 0 );
90 item0->Add( item5, 0, wxALIGN_CENTER|wxALL, 5 );
91
92 if (set_sizer)
93 {
94 parent->SetSizer( item0 );
95 if (call_fit)
96 item0->SetSizeHints( parent );
97 }
98
99 return item0;
100}
static const wxString PROXIM_COPYRIGHT
Copyright string.

References ID_LINE, ID_TEXT_PROGRAM_COPYRIGHT, ID_TEXT_PROGRAM_NAME, ID_TEXT_PROGRAM_VERSION, ProximConstants::PROXIM_COPYRIGHT, ProximConstants::PROXIM_TITLE, and WxConversion::toWxString().

Referenced by ProximAboutDialog().

Here is the call graph for this function:

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