1 // Copyright (C) 2003 Dolphin Project.
3 // This program is free software: you can redistribute it and/or modify
4 // it under the terms of the GNU General Public License as published by
5 // the Free Software Foundation, version 2.0.
7 // This program is distributed in the hope that it will be useful,
8 // but WITHOUT ANY WARRANTY; without even the implied warranty of
9 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
10 // GNU General Public License 2.0 for more details.
12 // A copy of the GPL 2.0 should have been included with the program.
13 // If not, see http://www.gnu.org/licenses/
15 // Official SVN repository and contact information can be found at
16 // http://code.google.com/p/dolphin-emu/
18 #ifndef __ISOPROPERTIES_h__
19 #define __ISOPROPERTIES_h__
23 #include <wx/filepicker.h>
24 #include <wx/statbmp.h>
25 #include <wx/imaglist.h>
26 #include <wx/fontmap.h>
27 #include <wx/treectrl.h>
28 #include <wx/gbsizer.h>
29 #include <wx/notebook.h>
30 #include <wx/mimetype.h>
34 #include "Filesystem.h"
36 #include "PatchEngine.h"
37 #include "ActionReplay.h"
38 #include "GeckoCodeDiag.h"
40 class CISOProperties
: public wxDialog
44 CISOProperties(const std::string fileName
,
47 const wxString
& title
= wxT("Properties"),
48 const wxPoint
& pos
= wxDefaultPosition
,
49 const wxSize
& size
= wxDefaultSize
,
50 long style
= wxDEFAULT_DIALOG_STYLE
|wxRESIZE_BORDER
);
51 virtual ~CISOProperties();
55 void ActionReplayList_Load();
56 bool SaveGameConfig();
60 DECLARE_EVENT_TABLE();
62 wxStaticBoxSizer
*sbGameConfig
;
63 wxStaticBoxSizer
*sbCoreOverrides
;
64 wxStaticBoxSizer
*sbWiiOverrides
;
65 wxStaticBoxSizer
*sbVideoOverrides
;
66 wxBoxSizer
*sEmuState
;
68 wxBoxSizer
*sPatchButtons
;
70 wxBoxSizer
*sCheatButtons
;
71 wxStaticBoxSizer
*sbISODetails
;
72 wxGridBagSizer
*sISODetails
;
73 wxStaticBoxSizer
*sbBannerDetails
;
74 wxGridBagSizer
*sBannerDetails
;
78 wxNotebook
*m_Notebook
;
79 wxPanel
*m_GameConfig
;
82 wxPanel
*m_Information
;
83 wxPanel
*m_Filesystem
;
85 wxStaticText
*OverrideText
;
87 wxCheckBox
*CPUThread
, *SkipIdle
, *MMU
, *SMC
, *TLBHack
;
89 wxCheckBox
*EnableProgressiveScan
, *EnableWideScreen
;
91 wxCheckBox
*ForceFiltering
,
92 *EFBCopyDisable
, *EFBToTextureEnable
,
93 *SafeTextureCache
, *DstAlphaPass
, *UseXFB
, *UseZTPSpeedupHack
;
94 wxStaticText
*Hacktext
;
95 wxArrayString arrayStringFor_Hack
;
97 wxStaticText
*WMTightnessText
;
98 wxTextCtrl
*WMTightness
;
100 wxButton
*EditConfig
;
101 wxStaticText
*EmuStateText
;
102 wxArrayString arrayStringFor_EmuState
;
104 wxTextCtrl
*EmuIssues
;
105 wxArrayString arrayStringFor_Patches
;
106 wxCheckListBox
*Patches
;
109 wxButton
*RemovePatch
;
110 wxArrayString arrayStringFor_Cheats
;
111 wxCheckListBox
*Cheats
;
114 wxButton
*RemoveCheat
;
115 wxArrayString arrayStringFor_Speedhacks
;
116 wxCheckListBox
*Speedhacks
;
117 wxButton
*EditSpeedhack
;
118 wxButton
*AddSpeedhack
;
119 wxButton
*RemoveSpeedhack
;
121 wxStaticText
*m_NameText
;
122 wxStaticText
*m_GameIDText
;
123 wxStaticText
*m_CountryText
;
124 wxStaticText
*m_MakerIDText
;
125 wxStaticText
*m_DateText
;
126 wxStaticText
*m_FSTText
;
127 wxStaticText
*m_LangText
;
128 wxStaticText
*m_ShortText
;
129 wxStaticText
*m_MakerText
;
130 wxStaticText
*m_CommentText
;
131 wxStaticText
*m_BannerText
;
133 wxTextCtrl
*m_GameID
;
134 wxTextCtrl
*m_Country
;
135 wxTextCtrl
*m_MakerID
;
138 wxArrayString arrayStringFor_Lang
;
140 wxTextCtrl
*m_ShortName
;
142 wxTextCtrl
*m_Comment
;
143 wxStaticBitmap
*m_Banner
;
145 wxTreeCtrl
*m_Treectrl
;
147 wxImageList
*m_iconList
;
149 Gecko::CodeConfigPanel
*m_geckocode_panel
;
172 ID_EFBTOTEXTUREENABLE
,
181 ID_ENABLEPROGRESSIVESCAN
,
227 IDM_EXTRACTAPPLOADER
,
232 void CreateGUIControls(bool);
233 void OnClose(wxCloseEvent
& event
);
234 void OnCloseClick(wxCommandEvent
& event
);
235 void OnEditConfig(wxCommandEvent
& event
);
236 void ListSelectionChanged(wxCommandEvent
& event
);
237 void PatchButtonClicked(wxCommandEvent
& event
);
238 void ActionReplayButtonClicked(wxCommandEvent
& event
);
239 void RightClickOnBanner(wxMouseEvent
& event
);
240 void OnBannerImageSave(wxCommandEvent
& event
);
241 void OnRightClickOnTree(wxTreeEvent
& event
);
242 void OnExtractFile(wxCommandEvent
& event
);
243 void OnExtractDir(wxCommandEvent
& event
);
244 void OnExtractDataFromHeader(wxCommandEvent
& event
);
245 void SetRefresh(wxCommandEvent
& event
);
246 void OnChangeBannerLang(wxCommandEvent
& event
);
248 GameListItem
*OpenGameListItem
;
250 std::vector
<const DiscIO::SFileInfo
*> GCFiles
;
251 typedef std::vector
<const DiscIO::SFileInfo
*>::iterator fileIter
;
253 size_t CreateDirectoryTree(wxTreeItemId
& parent
,
254 std::vector
<const DiscIO::SFileInfo
*> fileInfos
,
255 const size_t _FirstIndex
,
256 const size_t _LastIndex
);
257 void ExportDir(const char* _rFullPath
, const char* _rExportFilename
,
258 const int partitionNum
= 0);
261 std::string GameIniFile
;
263 void LoadGameConfig();
264 void PatchList_Load();
265 void PatchList_Save();
266 void ActionReplayList_Save();
267 void ChangeBannerDetails(int lang
);