#include <mainframe.hh>
Definition at line 31 of file mainframe.hh.
Public Member Functions | |
MainFrame () | |
Creates a new MainFrame. | |
Private Member Functions | |
bool | closeSRAM () |
Closes the current SRAM file. | |
void | loadGame (int game) |
Loads game data from the SRAM. | |
void | loadXRC () |
Loads the XRC controls and initializes this MainFrame. | |
void | openSRAM (const wxString &filename) |
Opens a Dragon Warrior SRAM file for editing. | |
bool | saveSRAM () |
Saves the current SRAM to disk. | |
bool | hasValidData () |
Checks the fields for valid data. | |
void | onArmorChange (wxCommandEvent &) |
Called when the hero's armor is changed. | |
void | onClose (wxCloseEvent &event) |
Called when the frame is about to be closed. | |
void | onExperienceEdit (wxCommandEvent &) |
Called when the hero's experience is changed. | |
void | onFileClose (wxCommandEvent &) |
Called when the file menu's close command is triggered. | |
void | onFileExit (wxCommandEvent &) |
Called when the file menu's exit command is triggered. | |
void | onFileMenuUpdate (wxUpdateUIEvent &event) |
Called to set the state of the file menu. | |
void | onFileOpen (wxCommandEvent &) |
Called when the file menu's open command is triggered. | |
void | onFileSave (wxCommandEvent &) |
Called when the file menu's save command is triggered. | |
void | onFileSaveAs (wxCommandEvent &) |
Called when the file menu's save as command is triggered. | |
void | onGameMenuUpdate (wxUpdateUIEvent &event) |
Called to set the state of the game menu. | |
void | onGameSelect (wxCommandEvent &event) |
Called when one of the game slots from the game menu is selected. | |
void | onGoldEdit (wxCommandEvent &) |
Called when the hero's gold is changed. | |
void | onGwaelinChange (wxCommandEvent &) |
Called when Gwaelin's location is changed. | |
void | onHelpAbout (wxCommandEvent &) |
Called when the help menu's about command is triggered. | |
void | onHerbsEdit (wxCommandEvent &) |
Called when the hero's herbs are changed. | |
void | onHPEdit (wxCommandEvent &) |
Called when the hero's HP is changed. | |
void | onInventoryChange (wxCommandEvent &event) |
Called when one of the hero's inventory items is changed. | |
void | onKeysEdit (wxCommandEvent &) |
Called when the hero's keys are changed. | |
void | onMPEdit (wxCommandEvent &) |
Called when the hero's MP is changed. | |
void | onNameEdit (wxCommandEvent &) |
Called when the hero's name is changed. | |
void | onQuestMarkerChange (wxCommandEvent &event) |
Called when one of the quest markers is changed. | |
void | onShieldChange (wxCommandEvent &) |
Called when the hero's shield is changed. | |
void | onWeaponChange (wxCommandEvent &) |
Called when the hero's weapon is changed. | |
Private Attributes | |
wxString | sramFile |
SRAMFile * | sram |
bool | enableEvents |
Friends | |
class | SRAMFileTarget |
MainFrame::MainFrame | ( | ) |
bool MainFrame::closeSRAM | ( | ) | [private] |
Closes the current SRAM file.
Definition at line 102 of file mainframe.cc.
void MainFrame::loadGame | ( | int | game | ) | [private] |
Loads game data from the SRAM.
game | The game slot to load. |
Definition at line 127 of file mainframe.cc.
void MainFrame::loadXRC | ( | ) | [private] |
void MainFrame::openSRAM | ( | const wxString & | filename | ) | [private] |
Opens a Dragon Warrior SRAM file for editing.
filename | The filename to open. |
Definition at line 220 of file mainframe.cc.
bool MainFrame::saveSRAM | ( | ) | [private] |
Saves the current SRAM to disk.
Definition at line 260 of file mainframe.cc.
bool MainFrame::hasValidData | ( | ) | [private] |
Checks the fields for valid data.
Definition at line 277 of file mainframe.cc.
void MainFrame::onArmorChange | ( | wxCommandEvent & | ) | [private] |
void MainFrame::onClose | ( | wxCloseEvent & | event | ) | [private] |
Called when the frame is about to be closed.
event | The triggering wxCloseEvent. |
Definition at line 327 of file mainframe.cc.
void MainFrame::onExperienceEdit | ( | wxCommandEvent & | ) | [private] |
void dwsrame::MainFrame::onFileClose | ( | wxCommandEvent & | ) | [inline, private] |
Called when the file menu's close command is triggered.
Definition at line 216 of file mainframe.hh.
void dwsrame::MainFrame::onFileExit | ( | wxCommandEvent & | ) | [inline, private] |
void MainFrame::onFileMenuUpdate | ( | wxUpdateUIEvent & | event | ) | [private] |
Called to set the state of the file menu.
event | The triggering wxUpdateUIEvent. |
Definition at line 350 of file mainframe.cc.
void MainFrame::onFileOpen | ( | wxCommandEvent & | ) | [private] |
void dwsrame::MainFrame::onFileSave | ( | wxCommandEvent & | ) | [inline, private] |
void MainFrame::onFileSaveAs | ( | wxCommandEvent & | ) | [private] |
Called when the file menu's save as command is triggered.
Definition at line 372 of file mainframe.cc.
void MainFrame::onGameMenuUpdate | ( | wxUpdateUIEvent & | event | ) | [private] |
Called to set the state of the game menu.
event | The triggering wxUpdateUIEvent. |
Definition at line 384 of file mainframe.cc.
void MainFrame::onGameSelect | ( | wxCommandEvent & | event | ) | [private] |
Called when one of the game slots from the game menu is selected.
event | The triggering wxCommandEvent. |
Definition at line 400 of file mainframe.cc.
void MainFrame::onGoldEdit | ( | wxCommandEvent & | ) | [private] |
void MainFrame::onGwaelinChange | ( | wxCommandEvent & | ) | [private] |
void MainFrame::onHelpAbout | ( | wxCommandEvent & | ) | [private] |
Called when the help menu's about command is triggered.
Definition at line 445 of file mainframe.cc.
void MainFrame::onHerbsEdit | ( | wxCommandEvent & | ) | [private] |
void MainFrame::onHPEdit | ( | wxCommandEvent & | ) | [private] |
void MainFrame::onInventoryChange | ( | wxCommandEvent & | event | ) | [private] |
Called when one of the hero's inventory items is changed.
event | The triggering wxCommandEvent. |
Definition at line 472 of file mainframe.cc.
void MainFrame::onKeysEdit | ( | wxCommandEvent & | ) | [private] |
void MainFrame::onMPEdit | ( | wxCommandEvent & | ) | [private] |
void MainFrame::onNameEdit | ( | wxCommandEvent & | ) | [private] |
void MainFrame::onQuestMarkerChange | ( | wxCommandEvent & | event | ) | [private] |
Called when one of the quest markers is changed.
event | The triggering wxCommandEvent. |
Definition at line 526 of file mainframe.cc.
void MainFrame::onShieldChange | ( | wxCommandEvent & | ) | [private] |
void MainFrame::onWeaponChange | ( | wxCommandEvent & | ) | [private] |
friend class SRAMFileTarget [friend] |
Definition at line 35 of file mainframe.hh.
wxString dwsrame::MainFrame::sramFile [private] |
Definition at line 38 of file mainframe.hh.
SRAMFile* dwsrame::MainFrame::sram [private] |
Definition at line 39 of file mainframe.hh.
bool dwsrame::MainFrame::enableEvents [private] |
Definition at line 40 of file mainframe.hh.