diff --git a/src/emucore/EventHandler.cxx b/src/emucore/EventHandler.cxx index aa158c4bb..91fdbb576 100644 --- a/src/emucore/EventHandler.cxx +++ b/src/emucore/EventHandler.cxx @@ -333,6 +333,14 @@ void EventHandler::handleSystemEvent(SystemEvent e, int, int) // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - void EventHandler::handleEvent(Event::Type event, bool pressed) { +#ifdef RETRON77 + static const string LEFT_DIFFICULTY = "P1 Skill"; + static const string RIGHT_DIFFICULTY = "P2 Skill"; +#else + static const string LEFT_DIFFICULTY = "Left Difficulty"; + static const string RIGHT_DIFFICULTY = "Right Difficulty"; +#endif + // Take care of special events that aren't part of the emulation core // or need to be preprocessed before passing them on switch(event) @@ -524,14 +532,14 @@ void EventHandler::handleEvent(Event::Type event, bool pressed) if(pressed) { myEvent.set(Event::ConsoleLeftDiffB, 0); - myOSystem.frameBuffer().showMessage("Left Difficulty A"); + myOSystem.frameBuffer().showMessage(LEFT_DIFFICULTY + " A"); } break; case Event::ConsoleLeftDiffB: if(pressed) { myEvent.set(Event::ConsoleLeftDiffA, 0); - myOSystem.frameBuffer().showMessage("Left Difficulty B"); + myOSystem.frameBuffer().showMessage(LEFT_DIFFICULTY + " B"); } break; case Event::ConsoleLeftDiffToggle: @@ -541,13 +549,13 @@ void EventHandler::handleEvent(Event::Type event, bool pressed) { myEvent.set(Event::ConsoleLeftDiffA, 0); myEvent.set(Event::ConsoleLeftDiffB, 1); - myOSystem.frameBuffer().showMessage("Left Difficulty B"); + myOSystem.frameBuffer().showMessage(LEFT_DIFFICULTY + " B"); } else { myEvent.set(Event::ConsoleLeftDiffA, 1); myEvent.set(Event::ConsoleLeftDiffB, 0); - myOSystem.frameBuffer().showMessage("Left Difficulty A"); + myOSystem.frameBuffer().showMessage(LEFT_DIFFICULTY + " A"); } myOSystem.console().switches().update(); } @@ -557,14 +565,14 @@ void EventHandler::handleEvent(Event::Type event, bool pressed) if(pressed) { myEvent.set(Event::ConsoleRightDiffB, 0); - myOSystem.frameBuffer().showMessage("Right Difficulty A"); + myOSystem.frameBuffer().showMessage(RIGHT_DIFFICULTY + " A"); } break; case Event::ConsoleRightDiffB: if(pressed) { myEvent.set(Event::ConsoleRightDiffA, 0); - myOSystem.frameBuffer().showMessage("Right Difficulty B"); + myOSystem.frameBuffer().showMessage(RIGHT_DIFFICULTY + " B"); } break; case Event::ConsoleRightDiffToggle: @@ -574,13 +582,13 @@ void EventHandler::handleEvent(Event::Type event, bool pressed) { myEvent.set(Event::ConsoleRightDiffA, 0); myEvent.set(Event::ConsoleRightDiffB, 1); - myOSystem.frameBuffer().showMessage("Right Difficulty B"); + myOSystem.frameBuffer().showMessage(RIGHT_DIFFICULTY + " B"); } else { myEvent.set(Event::ConsoleRightDiffA, 1); myEvent.set(Event::ConsoleRightDiffB, 0); - myOSystem.frameBuffer().showMessage("Right Difficulty A"); + myOSystem.frameBuffer().showMessage(RIGHT_DIFFICULTY + " A"); } myOSystem.console().switches().update(); } diff --git a/src/gui/CommandDialog.cxx b/src/gui/CommandDialog.cxx index d213fb2d3..2dd8399f3 100644 --- a/src/gui/CommandDialog.cxx +++ b/src/gui/CommandDialog.cxx @@ -29,6 +29,16 @@ #include "TIASurface.hxx" #include "CommandDialog.hxx" +#ifdef RETRON77 + static const string SELECT = "Mode"; + static const string LEFT_DIFF = "P1 Skill"; + static const string RIGHT_DIFF = "P2 Skill"; +#else + static const string SELECT = "Select"; + static const string LEFT_DIFF = "Left Diff"; + static const string RIGHT_DIFF = "Right Diff"; +#endif + // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - CommandDialog::CommandDialog(OSystem& osystem, DialogContainer& parent) : Dialog(osystem, parent, osystem.frameBuffer().font(), "Commands") @@ -57,7 +67,7 @@ CommandDialog::CommandDialog(OSystem& osystem, DialogContainer& parent) }; // Column 1 - bw = ADD_CD_BUTTON("Select", kSelectCmd); + bw = ADD_CD_BUTTON(SELECT, kSelectCmd); wid.push_back(bw); bw = ADD_CD_BUTTON("Reset", kResetCmd); wid.push_back(bw); @@ -112,8 +122,8 @@ void CommandDialog::loadConfig() { // Column 1 myColorButton->setLabel(instance().console().switches().tvColor() ? "Color Mode" : "B/W Mode"); - myLeftDiffButton->setLabel(instance().console().switches().leftDifficultyA() ? "Left Diff A" : "Left Diff B"); - myRightDiffButton->setLabel(instance().console().switches().rightDifficultyA() ? "Right Diff A" : "Right Diff B"); + myLeftDiffButton->setLabel(LEFT_DIFF + (instance().console().switches().leftDifficultyA() ? " A" : " B")); + myRightDiffButton->setLabel(RIGHT_DIFF + (instance().console().switches().rightDifficultyA() ? " A" : " B")); // Column 2 updateSlot(instance().state().currentSlot()); myTimeMachineButton->setLabel(instance().state().mode() == StateManager::Mode::TimeMachine ? diff --git a/src/gui/GameInfoDialog.cxx b/src/gui/GameInfoDialog.cxx index db0e1f6cf..f5e6e08c4 100644 --- a/src/gui/GameInfoDialog.cxx +++ b/src/gui/GameInfoDialog.cxx @@ -137,12 +137,23 @@ GameInfoDialog::GameInfoDialog( ////////////////////////////////////////////////////////////////////////////// // 2) Console properties +#ifdef RETRON77 + static const string TV_TYPE = "TV type "; + static const string LEFT_DIFFICULTY = "P1 Skill "; + static const string RIGHT_DIFFICULTY = "P2 Skill "; + +#else + static const string TV_TYPE = "TV type "; + static const string LEFT_DIFFICULTY = "Left Difficulty "; + static const string RIGHT_DIFFICULTY = "Right Difficulty "; +#endif + wid.clear(); tabID = myTab->addTab("Console"); xpos = HBORDER; ypos = VBORDER; - StaticTextWidget* s = new StaticTextWidget(myTab, font, xpos, ypos + 1, "TV type "); + StaticTextWidget* s = new StaticTextWidget(myTab, font, xpos, ypos + 1, TV_TYPE); myTVTypeGroup = new RadioButtonGroup(); RadioButtonWidget* r = new RadioButtonWidget(myTab, font, s->getRight(), ypos + 1, "Color", myTVTypeGroup); @@ -153,10 +164,10 @@ GameInfoDialog::GameInfoDialog( wid.push_back(r); ypos += lineHeight + VGAP * 2; - s = new StaticTextWidget(myTab, font, xpos, ypos+1, "Left difficulty "); + s = new StaticTextWidget(myTab, font, xpos, ypos+1, LEFT_DIFFICULTY); myLeftDiffGroup = new RadioButtonGroup(); r = new RadioButtonWidget(myTab, font, s->getRight(), ypos + 1, - "A (Expert)", myLeftDiffGroup); + "A (Expert)", myLeftDiffGroup); wid.push_back(r); ypos += lineHeight; r = new RadioButtonWidget(myTab, font, s->getRight(), ypos + 1, @@ -164,7 +175,7 @@ GameInfoDialog::GameInfoDialog( wid.push_back(r); ypos += lineHeight + VGAP * 2; - s = new StaticTextWidget(myTab, font, xpos, ypos+1, "Right difficulty "); + s = new StaticTextWidget(myTab, font, xpos, ypos+1, RIGHT_DIFFICULTY); myRightDiffGroup = new RadioButtonGroup(); r = new RadioButtonWidget(myTab, font, s->getRight(), ypos + 1, "A (Expert)", myRightDiffGroup); diff --git a/src/gui/GlobalPropsDialog.cxx b/src/gui/GlobalPropsDialog.cxx index 77bcf34ae..1a43265d4 100644 --- a/src/gui/GlobalPropsDialog.cxx +++ b/src/gui/GlobalPropsDialog.cxx @@ -28,6 +28,16 @@ #include "LauncherDialog.hxx" #include "GlobalPropsDialog.hxx" +#ifdef RETRON77 + static const string SELECT = "Mode"; + static const string LEFT_DIFFICULTY = "P1 Skill"; + static const string RIGHT_DIFFICULTY = "P2 Skill"; +#else + static const string SELECT = "Select"; + static const string LEFT_DIFFICULTY = "Left Difficulty"; + static const string RIGHT_DIFFICULTY = "Right Difficulty"; +#endif + // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - GlobalPropsDialog::GlobalPropsDialog(GuiObject* boss, const GUI::Font& font) : Dialog(boss->instance(), boss->parent(), font, "Power-on options"), @@ -74,7 +84,7 @@ GlobalPropsDialog::GlobalPropsDialog(GuiObject* boss, const GUI::Font& font) ypos += lineHeight + VGAP; // Left difficulty - new StaticTextWidget(this, font, xpos, ypos+1, "Left difficulty"); + new StaticTextWidget(this, font, xpos, ypos+1, LEFT_DIFFICULTY); items.clear(); VarList::push_back(items, "Default", "DEFAULT"); VarList::push_back(items, "A (Expert)", "A"); @@ -85,7 +95,7 @@ GlobalPropsDialog::GlobalPropsDialog(GuiObject* boss, const GUI::Font& font) ypos += lineHeight + VGAP; // Right difficulty - new StaticTextWidget(this, font, xpos, ypos+1, "Right difficulty"); + new StaticTextWidget(this, font, xpos, ypos+1, RIGHT_DIFFICULTY); // ... use same items as above myRightDiff = new PopUpWidget(this, font, xpos+lwidth, ypos, pwidth, lineHeight, items, ""); @@ -173,7 +183,7 @@ int GlobalPropsDialog::addHoldWidgets(const GUI::Font& font, int x, int y, // Console Select/Reset t = new StaticTextWidget(this, font, xpos, ypos+2, "Console"); ypos += t->getHeight() + VGAP; - myHoldSelect = new CheckboxWidget(this, font, xpos, ypos, "Select"); + myHoldSelect = new CheckboxWidget(this, font, xpos, ypos, SELECT); ypos += myHoldSelect->getHeight() + VGAP; myHoldReset = new CheckboxWidget(this, font, xpos, ypos, "Reset"); diff --git a/src/gui/MinUICommandDialog.cxx b/src/gui/MinUICommandDialog.cxx index cb5ab7df1..0326d3cf8 100644 --- a/src/gui/MinUICommandDialog.cxx +++ b/src/gui/MinUICommandDialog.cxx @@ -31,6 +31,16 @@ #include "MinUICommandDialog.hxx" +#ifdef RETRON77 + static const string SELECT = "Mode"; + static const string LEFT_DIFF = "P1 Skill"; + static const string RIGHT_DIFF = "P2 Skill"; +#else + static const string SELECT = "Select"; + static const string LEFT_DIFF = "Left Diff"; + static const string RIGHT_DIFF = "Right Diff"; +#endif + // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - MinUICommandDialog::MinUICommandDialog(OSystem& osystem, DialogContainer& parent) : Dialog(osystem, parent, osystem.frameBuffer().font(), "Commands"), @@ -61,7 +71,7 @@ MinUICommandDialog::MinUICommandDialog(OSystem& osystem, DialogContainer& parent }; // Column 1 - bw = ADD_CD_BUTTON("Select", kSelectCmd); + bw = ADD_CD_BUTTON(SELECT, kSelectCmd); wid.push_back(bw); bw = ADD_CD_BUTTON("Reset", kResetCmd); wid.push_back(bw); @@ -123,8 +133,8 @@ void MinUICommandDialog::loadConfig() { // Column 1 myColorButton->setLabel(instance().console().switches().tvColor() ? "Color Mode" : "B/W Mode"); - myLeftDiffButton->setLabel(instance().console().switches().leftDifficultyA() ? "P1 Skill A" : "P1 Skill B"); - myRightDiffButton->setLabel(instance().console().switches().rightDifficultyA() ? "P2 Skill A" : "P2 Skill B"); + myLeftDiffButton->setLabel(LEFT_DIFF + (instance().console().switches().leftDifficultyA() ? " A" : " B")); + myRightDiffButton->setLabel(RIGHT_DIFF + (instance().console().switches().rightDifficultyA() ? " A" : " B")); // Column 2 updateSlot(instance().state().currentSlot()); updateWinds();