2010-07-22 01:48:48 +00:00
|
|
|
|
|
|
|
#ifndef __GECKOCODEDIAG_h__
|
|
|
|
#define __GECKOCODEDIAG_h__
|
|
|
|
|
|
|
|
#include "GeckoCode.h"
|
|
|
|
#include "GeckoCodeConfig.h"
|
|
|
|
|
|
|
|
#include "wx/wx.h"
|
|
|
|
|
|
|
|
namespace Gecko
|
|
|
|
{
|
|
|
|
|
|
|
|
|
|
|
|
class CodeConfigPanel : public wxPanel
|
|
|
|
{
|
|
|
|
public:
|
|
|
|
CodeConfigPanel(wxWindow* const parent);
|
|
|
|
|
|
|
|
|
2010-07-23 05:22:12 +00:00
|
|
|
void LoadCodes(const IniFile& inifile, const std::string& gameid = "");
|
2010-07-22 01:48:48 +00:00
|
|
|
const std::vector<GeckoCode>& GetCodes() const { return m_gcodes; }
|
|
|
|
|
|
|
|
protected:
|
|
|
|
void UpdateInfoBox(wxCommandEvent&);
|
|
|
|
void ToggleCode(wxCommandEvent& evt);
|
2010-07-23 05:22:12 +00:00
|
|
|
void DownloadCodes(wxCommandEvent&);
|
|
|
|
//void ApplyChanges(wxCommandEvent&);
|
|
|
|
|
|
|
|
void UpdateCodeList();
|
2010-07-22 01:48:48 +00:00
|
|
|
|
|
|
|
private:
|
|
|
|
std::vector<GeckoCode> m_gcodes;
|
|
|
|
|
2010-07-23 05:22:12 +00:00
|
|
|
std::string m_gameid;
|
|
|
|
|
2010-07-22 01:48:48 +00:00
|
|
|
// wxwidgets stuff
|
|
|
|
wxCheckListBox *m_listbox_gcodes;
|
|
|
|
struct
|
|
|
|
{
|
2010-07-23 05:22:12 +00:00
|
|
|
wxStaticText *label_name, *label_notes, *label_creator;
|
|
|
|
wxTextCtrl *textctrl_notes;
|
2010-07-22 01:48:48 +00:00
|
|
|
wxListBox *listbox_codes;
|
|
|
|
} m_infobox;
|
|
|
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
2010-07-22 07:55:35 +00:00
|
|
|
#endif
|
2010-07-23 05:22:12 +00:00
|
|
|
|