OpenCPN Partial API docs
Loading...
Searching...
No Matches
about.h
1/******************************************************************************
2 *
3 * Project: OpenCPN
4 * Purpose: About Dialog
5 * Author: David Register
6 *
7 ***************************************************************************
8 * Copyright (C) 2010 by David S. Register *
9 * *
10 * This program is free software; you can redistribute it and/or modify *
11 * it under the terms of the GNU General Public License as published by *
12 * the Free Software Foundation; either version 2 of the License, or *
13 * (at your option) any later version. *
14 * *
15 * This program is distributed in the hope that it will be useful, *
16 * but WITHOUT ANY WARRANTY; without even the implied warranty of *
17 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
18 * GNU General Public License for more details. *
19 * *
20 * You should have received a copy of the GNU General Public License *
21 * along with this program; if not, write to the *
22 * Free Software Foundation, Inc., *
23 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. *
24 ***************************************************************************
25 *
26
27 */
28
29#ifndef _ABOUT_H_
30#define _ABOUT_H_
31
32#include <wx/notebook.h>
33
34// Constants
35
36#define ID_DIALOG 10001
37
38#define SYMBOL_ABOUT_TITLE _("About OpenCPN")
39
40#define ID_DONATE 10010
41#define ID_COPYINI 10011
42#define ID_COPYLOG 10012
43
44#define ID_NOTEBOOK_HELP 10002
45
46class wxHtmlWindow;
47
52class about : public wxDialog {
53 DECLARE_EVENT_TABLE()
54
55public:
56 explicit about();
57 explicit about(wxWindow* parent, wxString License_Data_Locn,
58 wxWindowID id = ID_DIALOG,
59 const wxString& caption = SYMBOL_ABOUT_TITLE,
60 const wxPoint& pos = wxDefaultPosition,
61 const wxSize& size = wxSize(500, 500),
62 long style = wxCAPTION | wxRESIZE_BORDER | wxSYSTEM_MENU |
63 wxCLOSE_BOX);
64 bool Create(wxWindow* parent, wxWindowID id = ID_DIALOG,
65 const wxString& caption = SYMBOL_ABOUT_TITLE,
66 const wxPoint& pos = wxDefaultPosition,
67 const wxSize& size = wxSize(500, 500),
68 long style = wxCAPTION | wxRESIZE_BORDER | wxSYSTEM_MENU |
69 wxCLOSE_BOX);
70
71 void RecalculateSize(void);
72
73private:
74 void CreateControls(void);
75 void Populate(void);
76 void OnXidOkClick(wxCommandEvent& event);
77 void OnNBPageChange(wxNotebookEvent& event);
78 void OnDonateClick(wxCommandEvent& event);
79 void OnCopyClick(wxCommandEvent& event);
80 void OnClose(wxCloseEvent& event);
81 void SetColorScheme(void);
82
83 wxString m_DataLocn;
84 wxWindow* m_parent;
85 bool m_btips_loaded;
86 bool m_blicensePageSet;
87
88 wxPanel* itemPanelAbout;
89 wxPanel* itemPanelAuthors;
90 wxPanel* itemPanelLicense;
91 wxPanel* itemPanelTips;
92
93 wxTextCtrl* pAuthorTextCtl;
94 wxTextCtrl* pLicenseTextCtl;
95 wxNotebook* pNotebook;
96 wxHtmlWindow* pAboutHTMLCtl;
97 wxHtmlWindow* pLicenseHTMLCtl;
98 wxHtmlWindow* pAuthorHTMLCtl;
99
100 wxSize m_displaySize;
101};
102
103#endif // _ABOUT_H_
Represents the About dialog for OpenCPN.
Definition about.h:52