1 /*
2  * This file is part of the Code::Blocks IDE and licensed under the GNU General Public License, version 3
3  * http://www.gnu.org/licenses/gpl-3.0.html
4  *
5  * $Revision: 10912 $
6  * $Id: dlgaboutplugin.cpp 10912 2016-09-25 16:10:13Z fuscated $
7  * $HeadURL: svn://svn.code.sf.net/p/codeblocks/code/branches/release-20.xx/src/src/dlgaboutplugin.cpp $
8  */
9 
10 #include "sdk.h"
11 #ifndef CB_PRECOMP
12     #include <wx/button.h>
13     #include <wx/intl.h>
14     #include <wx/stattext.h>
15     #include <wx/string.h>
16     #include <wx/textctrl.h>
17     #include <wx/xrc/xmlres.h>
18 #endif
19 
20 #include "cbplugin.h"
21 #include "dlgaboutplugin.h" // class's header file
22 
23 // class constructor
dlgAboutPlugin(wxWindow * parent,const PluginInfo * pi)24 dlgAboutPlugin::dlgAboutPlugin(wxWindow* parent, const PluginInfo* pi)
25 {
26 	wxXmlResource::Get()->LoadObject(this, parent, _T("dlgAboutPlugin"),_T("wxScrollingDialog"));
27     XRCCTRL(*this, "wxID_CANCEL", wxButton)->SetDefault();
28 
29 	XRCCTRL(*this, "lblTitle", wxStaticText)->SetLabel(pi->title);
30 	XRCCTRL(*this, "txtDescription", wxTextCtrl)->SetValue(pi->description);
31 	XRCCTRL(*this, "txtThanksTo", wxTextCtrl)->SetValue(pi->thanksTo);
32 	XRCCTRL(*this, "txtLicense", wxTextCtrl)->SetValue(pi->license);
33 	XRCCTRL(*this, "lblName", wxStaticText)->SetLabel(pi->name);
34 	XRCCTRL(*this, "lblVersion", wxStaticText)->SetLabel(pi->version);
35 	XRCCTRL(*this, "lblAuthor", wxStaticText)->SetLabel(pi->author);
36 	XRCCTRL(*this, "lblEmail", wxStaticText)->SetLabel(pi->authorEmail);
37 	XRCCTRL(*this, "lblWebsite", wxStaticText)->SetLabel(pi->authorWebsite);
38 
39 	Fit();
40 }
41 
42 // class destructor
~dlgAboutPlugin()43 dlgAboutPlugin::~dlgAboutPlugin()
44 {
45 	// insert your code here
46 }
47