diff --git a/src/emucore/Bezel.cxx b/src/common/Bezel.cxx similarity index 83% rename from src/emucore/Bezel.cxx rename to src/common/Bezel.cxx index 214d707f9..e4fb0e5c8 100644 --- a/src/emucore/Bezel.cxx +++ b/src/common/Bezel.cxx @@ -137,24 +137,32 @@ bool Bezel::load() const Int32 h = mySurface->height(); uInt32 top, bottom, left, right; - if(settings.getBool("bezel.autoborders")) + if(settings.getBool("bezel.win.auto")) { // Determine transparent window inside bezel image - top = borderSize(w >> 1, 0, h, w); - bottom = h - 1 - borderSize(w >> 1, h - 1, h, -w); - left = borderSize(0, (bottom + top) >> 1, w, 1); - right = w - 1 - borderSize(w - 1, (bottom + top) >> 1, w, -1); + uInt32 xCenter, yCenter; + + xCenter = w >> 1; + top = borderSize(xCenter, 0, h, w); + bottom = h - 1 - borderSize(xCenter, h - 1, h, -w); + yCenter = (bottom + top) >> 1; + left = borderSize(0, yCenter, w, 1); + right = w - 1 - borderSize(w - 1, yCenter, w, -1); } else { - left = std::min(w, settings.getInt("bezel.leftborder")); - right = w - 1 - std::min(w, settings.getInt("bezel.rightborder")); - top = std::min(h, settings.getInt("bezel.topborder")); - bottom = h - 1 - std::min(h, settings.getInt("bezel.bottomborder")); + // BP: 13, 13, 0, 0% + // HY: 12, 12, 0, 0% + // P1: 25, 25, 11, 22% + // P2: 23, 23, 7, 20% + left = std::min(w - 1, static_cast(w * settings.getInt("bezel.win.left") / 100. + .5)); + right = w - 1 - std::min(w - 1, static_cast(w * settings.getInt("bezel.win.right") / 100. + .5)); + top = std::min(h - 1, static_cast(h * settings.getInt("bezel.win.top") / 100. + .5)); + bottom = h - 1 - std::min(h - 1, static_cast(h * settings.getInt("bezel.win.bottom") / 100. + .5)); } - cerr << (int)(right - left + 1) << " x " << (int)(bottom - top + 1) << " = " - << double((int)(right - left + 1)) / double((int)(bottom - top + 1)); + //cerr << (int)(right - left + 1) << " x " << (int)(bottom - top + 1) << " = " + // << double((int)(right - left + 1)) / double((int)(bottom - top + 1)); // Disable bezel is no transparent window was found if (left < right && top < bottom) diff --git a/src/emucore/Bezel.hxx b/src/common/Bezel.hxx similarity index 100% rename from src/emucore/Bezel.hxx rename to src/common/Bezel.hxx diff --git a/src/common/PKeyboardHandler.cxx b/src/common/PKeyboardHandler.cxx index 601e83108..fad308fd7 100644 --- a/src/common/PKeyboardHandler.cxx +++ b/src/common/PKeyboardHandler.cxx @@ -623,6 +623,7 @@ PhysicalKeyboardHandler::DefaultCommonMapping = { #endif { Event::OptionsMenuMode, KBDK_TAB }, { Event::CmdMenuMode, KBDK_BACKSLASH }, + { Event::ToggleBezel, KBDK_B, KBDM_CTRL }, { Event::TimeMachineMode, KBDK_T, KBDM_SHIFT }, { Event::DebuggerMode, KBDK_GRAVE }, { Event::PlusRomsSetupMode, KBDK_P, KBDM_SHIFT | KBDM_CTRL | MOD3 }, diff --git a/src/common/jsonDefinitions.hxx b/src/common/jsonDefinitions.hxx index b3e74590f..0f59cc0f4 100644 --- a/src/common/jsonDefinitions.hxx +++ b/src/common/jsonDefinitions.hxx @@ -386,6 +386,7 @@ NLOHMANN_JSON_SERIALIZE_ENUM(Event::Type, { {Event::ToggleBits, "ToggleBits"}, {Event::ToggleFixedColors, "ToggleFixedColors"}, {Event::ToggleFrameStats, "ToggleFrameStats"}, + {Event::ToggleBezel, "ToggleBezel"}, {Event::ExitGame, "ExitGame"}, {Event::SettingDecrease, "SettingDecrease"}, {Event::SettingIncrease, "SettingIncrease"}, diff --git a/src/common/module.mk b/src/common/module.mk index 8c34ef8c1..c2805f9d2 100644 --- a/src/common/module.mk +++ b/src/common/module.mk @@ -4,6 +4,7 @@ MODULE_OBJS := \ src/common/AudioQueue.o \ src/common/AudioSettings.o \ src/common/Base.o \ + src/emucore/Bezel.o \ src/common/DevSettingsHandler.o \ src/common/EventHandlerSDL2.o \ src/common/FBBackendSDL2.o \ diff --git a/src/emucore/Event.hxx b/src/emucore/Event.hxx index 5020f6162..a5411cdcd 100644 --- a/src/emucore/Event.hxx +++ b/src/emucore/Event.hxx @@ -126,7 +126,7 @@ class Event ToggleBLCollision, ToggleBLBit, TogglePFCollision, TogglePFBit, ToggleCollisions, ToggleBits, ToggleFixedColors, - ToggleFrameStats, ToggleSAPortOrder, ExitGame, + ToggleFrameStats, ToggleBezel, ToggleSAPortOrder, ExitGame, SettingDecrease, SettingIncrease, PreviousSetting, NextSetting, ToggleAdaptRefresh, PreviousMultiCartRom, // add new (after Version 4) events from here to avoid that user remapped events get overwritten diff --git a/src/emucore/EventHandler.cxx b/src/emucore/EventHandler.cxx index 7c0b04e1b..1ab4ca0e5 100644 --- a/src/emucore/EventHandler.cxx +++ b/src/emucore/EventHandler.cxx @@ -1517,6 +1517,14 @@ void EventHandler::handleEvent(Event::Type event, Int32 value, bool repeated) if(pressed && !repeated) myOSystem.toggleTimeMachine(); return; + case Event::ToggleBezel: + if(pressed && !repeated) + { + myOSystem.frameBuffer().toggleBezel(); + myGlobalKeyHandler->setSetting(GlobalKeyHandler::Setting::BEZEL); + } + return; + #ifdef IMAGE_SUPPORT case Event::ToggleContSnapshots: if(pressed && !repeated) myOSystem.png().toggleContinuousSnapshots(false); @@ -2827,6 +2835,7 @@ EventHandler::EmulActionList EventHandler::ourEmulActionList = { { { Event::ExitMode, "Exit current Stella menu/mode" }, { Event::OptionsMenuMode, "Enter Options menu UI" }, { Event::CmdMenuMode, "Toggle Commands menu UI" }, + { Event::ToggleBezel, "Toggle bezel display" }, { Event::HighScoresMenuMode, "Toggle High Scores UI" }, { Event::PlusRomsSetupMode, "Toggle PlusROMs setup UI" }, { Event::TogglePauseMode, "Toggle Pause mode" }, @@ -3148,7 +3157,7 @@ EventHandler::MenuActionList EventHandler::ourMenuActionList = { { const Event::EventSet EventHandler::MiscEvents = { Event::Quit, Event::ReloadConsole, Event::Fry, Event::StartPauseMode, Event::TogglePauseMode, Event::OptionsMenuMode, Event::CmdMenuMode, - Event::PlusRomsSetupMode, Event::ExitMode, + Event::ToggleBezel, Event::PlusRomsSetupMode, Event::ExitMode, Event::ToggleTurbo, Event::DecreaseSpeed, Event::IncreaseSpeed, Event::TakeSnapshot, Event::ToggleContSnapshots, Event::ToggleContSnapshotsFrame, // Event::MouseAxisXMove, Event::MouseAxisYMove, diff --git a/src/emucore/EventHandler.hxx b/src/emucore/EventHandler.hxx index 49b388f2c..a241de18b 100644 --- a/src/emucore/EventHandler.hxx +++ b/src/emucore/EventHandler.hxx @@ -537,7 +537,7 @@ class EventHandler #else REFRESH_SIZE = 0, #endif - EMUL_ACTIONLIST_SIZE = 232 + PNG_SIZE + COMBO_SIZE + REFRESH_SIZE, + EMUL_ACTIONLIST_SIZE = 233 + PNG_SIZE + COMBO_SIZE + REFRESH_SIZE, MENU_ACTIONLIST_SIZE = 20 ; diff --git a/src/emucore/FrameBuffer.cxx b/src/emucore/FrameBuffer.cxx index fb4421c67..9237ba122 100644 --- a/src/emucore/FrameBuffer.cxx +++ b/src/emucore/FrameBuffer.cxx @@ -1263,6 +1263,25 @@ void FrameBuffer::switchVideoMode(int direction) } } +// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +void FrameBuffer::toggleBezel(bool toggle) +{ + bool enabled = myOSystem.settings().getBool("bezel.show"); + + if(toggle) + { + if(myBufferType == BufferType::Emulator && + (fullScreen() || myOSystem.settings().getBool("bezel.windowed"))) + { + enabled = !enabled; + myOSystem.settings().setValue("bezel.show", enabled); + myBezel->load(); + applyVideoMode(); + } + } + myOSystem.frameBuffer().showTextMessage(enabled ? "Bezel enabled" : "Bezel disabled"); +} + // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - FBInitStatus FrameBuffer::applyVideoMode() { @@ -1328,7 +1347,6 @@ FBInitStatus FrameBuffer::applyVideoMode() return status; } - // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - double FrameBuffer::maxWindowZoom() const { diff --git a/src/emucore/FrameBuffer.hxx b/src/emucore/FrameBuffer.hxx index 54930d2f9..cd65c7977 100644 --- a/src/emucore/FrameBuffer.hxx +++ b/src/emucore/FrameBuffer.hxx @@ -257,6 +257,11 @@ class FrameBuffer */ void switchVideoMode(int direction = +1); + /** + Toggles the bezel display. + */ + void toggleBezel(bool toggle = true); + /** Sets the state of the cursor (hidden or grabbed) based on the current mode. diff --git a/src/emucore/GlobalKeyHandler.cxx b/src/emucore/GlobalKeyHandler.cxx index a6b61a64c..60e18602b 100644 --- a/src/emucore/GlobalKeyHandler.cxx +++ b/src/emucore/GlobalKeyHandler.cxx @@ -208,6 +208,8 @@ bool GlobalKeyHandler::skipAVSetting() const myOSystem.settings().getInt("tv.scanlines") > 0; const bool isSoftwareRenderer = myOSystem.settings().getString("video") == "software"; + const bool allowBezel = + myOSystem.settings().getBool("bezel.windowed") || isFullScreen; return (mySetting == Setting::OVERSCAN && !isFullScreen) || (mySetting == Setting::ZOOM && isFullScreen) @@ -223,7 +225,8 @@ bool GlobalKeyHandler::skipAVSetting() const && mySetting <= Setting::NTSC_BLEEDING && !isCustomFilter) || (mySetting == Setting::SCANLINE_MASK && !hasScanlines) - || (mySetting == Setting::INTERPOLATION && isSoftwareRenderer); + || (mySetting == Setting::INTERPOLATION && isSoftwareRenderer) + || (mySetting == Setting::BEZEL && !allowBezel); } // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - @@ -391,6 +394,7 @@ GlobalKeyHandler::SettingData GlobalKeyHandler::getSettingData(const Setting set {Setting::SCANLINES, {true, std::bind(&TIASurface::changeScanlineIntensity, &myOSystem.frameBuffer().tiaSurface(), _1)}}, {Setting::SCANLINE_MASK, {false, std::bind(&TIASurface::cycleScanlineMask, &myOSystem.frameBuffer().tiaSurface(), _1)}}, {Setting::INTERPOLATION, {false, std::bind(&Console::toggleInter, &myOSystem.console(), _1)}}, + {Setting::BEZEL, {false, std::bind(&FrameBuffer::toggleBezel, &myOSystem.frameBuffer(), _1)}}, // *** Input group *** {Setting::DIGITAL_DEADZONE, {true, std::bind(&PhysicalJoystickHandler::changeDigitalDeadZone, &joyHandler(), _1)}}, {Setting::ANALOG_DEADZONE, {true, std::bind(&PhysicalJoystickHandler::changeAnalogPaddleDeadZone, &joyHandler(), _1)}}, diff --git a/src/emucore/GlobalKeyHandler.hxx b/src/emucore/GlobalKeyHandler.hxx index ba307669d..bb4fb42bb 100644 --- a/src/emucore/GlobalKeyHandler.hxx +++ b/src/emucore/GlobalKeyHandler.hxx @@ -73,6 +73,7 @@ class GlobalKeyHandler SCANLINES, SCANLINE_MASK, INTERPOLATION, + BEZEL, // *** Input group *** DIGITAL_DEADZONE, ANALOG_DEADZONE, @@ -128,7 +129,7 @@ class GlobalKeyHandler // *** Ranges *** NUM_ADJ, START_AV_ADJ = VOLUME, - END_AV_ADJ = INTERPOLATION, + END_AV_ADJ = BEZEL, START_INPUT_ADJ = DIGITAL_DEADZONE, END_INPUT_ADJ = MOUSE_RANGE, START_DEBUG_ADJ = DEVELOPER, diff --git a/src/emucore/Settings.cxx b/src/emucore/Settings.cxx index ad951ccb3..3eff1c00f 100644 --- a/src/emucore/Settings.cxx +++ b/src/emucore/Settings.cxx @@ -64,11 +64,11 @@ Settings::Settings() setPermanent("pausedim", "true"); setPermanent("bezel.show", "true"); setPermanent("bezel.windowed", "false"); - setPermanent("bezel.autoborders", "true"); - setPermanent("bezel.leftborder", "0"); - setPermanent("bezel.rightborder", "0"); - setPermanent("bezel.topborder", "0"); - setPermanent("bezel.bottomborder", "0"); + setPermanent("bezel.win.auto", "true"); + setPermanent("bezel.win.left", "12"); + setPermanent("bezel.win.right", "12"); + setPermanent("bezel.win.top", "0"); + setPermanent("bezel.win.bottom", "0"); // TIA specific options setPermanent("tia.inter", "false"); setPermanent("tia.zoom", "3"); @@ -546,13 +546,14 @@ void Settings::usage() << " -turbo <1|0> Enable 'Turbo' mode for maximum emulation speed\n" << " -uimessages <1|0> Show onscreen UI messages for different events\n" << " -pausedim <1|0> Enable emulation dimming in pause mode\n" - << " -bezel.show <1|0> Show bezel left and right of emulation\n" - << " -bezel.windowed <1|0> Show bezel in windowed modes\n" - << " -bezel.autoborders <1|0> Automatically set bezel window borders\n" - << " -bezel.leftborder Set left bezel window border\n" - << " -bezel.rightborder Set right bezel window border\n" - << " -bezel.topborder Set top bezel window border\n" - << " -bezel.bottomborder Set bottom bezel window border\n" + << endl + << " -bezel.show <1|0> Show bezel around emulation window\n" + << " -bezel.windowed <1|0> Show bezel in windowed modes\n" + << " -bezel.win.auto <1|0> Automatically set bezel window position\n" + << " -bezel.win.left <0-40> Set left bezel window position [%]\n" + << " -bezel.win.right <0-40> Set right bezel window position [%]\n" + << " -bezel.win.top <0-40> Set top bezel window position [%]\n" + << " -bezel.win.bottom <0-40> Set bottom bezel window position [%]\n" << endl #ifdef SOUND_SUPPORT << " -audio.enabled <1|0> Enable audio\n" diff --git a/src/emucore/module.mk b/src/emucore/module.mk index 754dafe5f..43376a19d 100644 --- a/src/emucore/module.mk +++ b/src/emucore/module.mk @@ -2,8 +2,7 @@ MODULE := src/emucore MODULE_OBJS := \ src/emucore/AtariVox.o \ - src/emucore/Bezel.o \ - src/emucore/Bankswitch.o \ + src/emucore/Bankswitch.o \ src/emucore/Booster.o \ src/emucore/Cart.o \ src/emucore/CartARM.o \ diff --git a/src/gui/VideoAudioDialog.cxx b/src/gui/VideoAudioDialog.cxx index 714570df6..ad7ddc92e 100644 --- a/src/gui/VideoAudioDialog.cxx +++ b/src/gui/VideoAudioDialog.cxx @@ -477,51 +477,47 @@ void VideoAudioDialog::addBezelTab() ypos += lineHeight + VGAP * 3; myBezelShowWindowed = new CheckboxWidget(myTab, _font, xpos, ypos, - "Show in windowed modes"); - //myBezelShowWindowed->setToolTip(Event::BezelToggle); + "Windowed modes"); + myBezelShowWindowed->setToolTip("Enable bezels in windowed modes as well."); wid.push_back(myBezelShowWindowed); // Disable auto borders ypos += lineHeight + VGAP * 1; - myManualBorders = new CheckboxWidget(myTab, _font, xpos, ypos, - "Manual borders", kAutoBordersChanged); - myManualBorders->setToolTip("Enable if automatic border detection fails."); - wid.push_back(myManualBorders); + myManualWindow = new CheckboxWidget(myTab, _font, xpos, ypos, + "Manual emulation window", kAutoWindowChanged); + myManualWindow->setToolTip("Enable if automatic window detection fails."); + wid.push_back(myManualWindow); xpos += INDENT; const int lWidth = _font.getStringWidth("Bottom "); - const int sWidth = myBezelPath->getRight() - xpos - lWidth - 5.5 * fontWidth; // _w - HBORDER - xpos - lwidth; + const int sWidth = myBezelPath->getRight() - xpos - lWidth - 4.5 * fontWidth; // _w - HBORDER - xpos - lwidth; ypos += lineHeight + VGAP * 1; - myLeftBorderSlider = new SliderWidget(myTab, _font, xpos, ypos, sWidth, lineHeight, - "Left ", 0, 0, 5 * fontWidth, "px"); - myLeftBorderSlider->setMinValue(0); myLeftBorderSlider->setMaxValue(500); - myLeftBorderSlider->setTickmarkIntervals(10); - //myLeftBorderSlider->setToolTip(Event::VolumeDecrease, Event::VolumeIncrease); - wid.push_back(myLeftBorderSlider); + myWinLeftSlider = new SliderWidget(myTab, _font, xpos, ypos, sWidth, lineHeight, + "Left ", 0, 0, 4 * fontWidth, "%"); + myWinLeftSlider->setMinValue(0); myWinLeftSlider->setMaxValue(40); + myWinLeftSlider->setTickmarkIntervals(4); + wid.push_back(myWinLeftSlider); ypos += lineHeight + VGAP * 1; - myRightBorderSlider = new SliderWidget(myTab, _font, xpos, ypos, sWidth, lineHeight, - "Right ", 0, 0, 5 * fontWidth, "px"); - myRightBorderSlider->setMinValue(0); myRightBorderSlider->setMaxValue(500); - myRightBorderSlider->setTickmarkIntervals(10); - //myRightBorderSlider->setToolTip(Event::VolumeDecrease, Event::VolumeIncrease); - wid.push_back(myRightBorderSlider); + myWinRightSlider = new SliderWidget(myTab, _font, xpos, ypos, sWidth, lineHeight, + "Right ", 0, 0, 4 * fontWidth, "%"); + myWinRightSlider->setMinValue(0); myWinRightSlider->setMaxValue(40); + myWinRightSlider->setTickmarkIntervals(4); + wid.push_back(myWinRightSlider); ypos += lineHeight + VGAP * 1; - myTopBorderSlider = new SliderWidget(myTab, _font, xpos, ypos, sWidth, lineHeight, - "Top ", 0, 0, 5 * fontWidth, "px"); - myTopBorderSlider->setMinValue(0); myTopBorderSlider->setMaxValue(250); - myTopBorderSlider->setTickmarkIntervals(5); - //myTopBorderSlider->setToolTip(Event::VolumeDecrease, Event::VolumeIncrease); - wid.push_back(myTopBorderSlider); + myWinTopSlider = new SliderWidget(myTab, _font, xpos, ypos, sWidth, lineHeight, + "Top ", 0, 0, 4 * fontWidth, "%"); + myWinTopSlider->setMinValue(0); myWinTopSlider->setMaxValue(40); + myWinTopSlider->setTickmarkIntervals(4); + wid.push_back(myWinTopSlider); ypos += lineHeight + VGAP; - myBtmBorderSlider = new SliderWidget(myTab, _font, xpos, ypos, sWidth, lineHeight, - "Bottom ", 0, 0, 5 * fontWidth, "px"); - myBtmBorderSlider->setMinValue(0); myBtmBorderSlider->setMaxValue(250); - myBtmBorderSlider->setTickmarkIntervals(5); - //myBtmBorderSlider->setToolTip(Event::VolumeDecrease, Event::VolumeIncrease); - wid.push_back(myBtmBorderSlider); + myWinBottomSlider = new SliderWidget(myTab, _font, xpos, ypos, sWidth, lineHeight, + "Bottom ", 0, 0, 4 * fontWidth, "%"); + myWinBottomSlider->setMinValue(0); myWinBottomSlider->setMaxValue(40); + myWinBottomSlider->setTickmarkIntervals(4); + wid.push_back(myWinBottomSlider); // Add items for tab 4 addToFocusList(wid, myTab, tabID); @@ -774,11 +770,11 @@ void VideoAudioDialog::loadConfig() myBezelEnableCheckbox->setState(settings.getBool("bezel.show")); myBezelPath->setText(settings.getString("bezel.dir")); myBezelShowWindowed->setState(settings.getBool("bezel.windowed")); - myManualBorders->setState(!settings.getBool("bezel.autoborders")); - myLeftBorderSlider->setValue(settings.getInt("bezel.leftborder")); - myRightBorderSlider->setValue(settings.getInt("bezel.rightborder")); - myTopBorderSlider->setValue(settings.getInt("bezel.topborder")); - myBtmBorderSlider->setValue(settings.getInt("bezel.bottomborder")); + myManualWindow->setState(!settings.getBool("bezel.win.auto")); + myWinLeftSlider->setValue(settings.getInt("bezel.win.left")); + myWinRightSlider->setValue(settings.getInt("bezel.win.right")); + myWinTopSlider->setValue(settings.getInt("bezel.win.top")); + myWinBottomSlider->setValue(settings.getInt("bezel.win.bottom")); handleBezelChange(); ///////////////////////////////////////////////////////////////////////////// @@ -909,11 +905,11 @@ void VideoAudioDialog::saveConfig() settings.setValue("bezel.show", myBezelEnableCheckbox->getState()); settings.setValue("bezel.dir", myBezelPath->getText()); settings.setValue("bezel.windowed", myBezelShowWindowed->getState()); - settings.setValue("bezel.autoborders", !myManualBorders->getState()); - settings.setValue("bezel.leftborder", myLeftBorderSlider->getValueLabel()); - settings.setValue("bezel.rightborder", myRightBorderSlider->getValueLabel()); - settings.setValue("bezel.topborder", myTopBorderSlider->getValueLabel()); - settings.setValue("bezel.bottomborder", myBtmBorderSlider->getValueLabel()); + settings.setValue("bezel.win.auto", !myManualWindow->getState()); + settings.setValue("bezel.win.left", myWinLeftSlider->getValueLabel()); + settings.setValue("bezel.win.right", myWinRightSlider->getValueLabel()); + settings.setValue("bezel.win.top", myWinTopSlider->getValueLabel()); + settings.setValue("bezel.win.bottom", myWinBottomSlider->getValueLabel()); // Note: The following has to happen after all video related setting have been saved if(instance().hasConsole()) @@ -1053,7 +1049,7 @@ void VideoAudioDialog::setDefaults() myBezelEnableCheckbox->setState(true); myBezelPath->setText(instance().userDir().getShortPath()); myBezelShowWindowed->setState(false); - myManualBorders->setState(false); + myManualWindow->setState(false); handleBezelChange(); break; @@ -1223,15 +1219,15 @@ void VideoAudioDialog::handlePhosphorChange() void VideoAudioDialog::handleBezelChange() { const bool enable = myBezelEnableCheckbox->getState(); - const bool nonAuto = myManualBorders->getState(); + const bool nonAuto = myManualWindow->getState(); myOpenBrowserButton->setEnabled(enable); myBezelPath->setEnabled(enable); myBezelShowWindowed->setEnabled(enable); - myLeftBorderSlider->setEnabled(enable && nonAuto); - myRightBorderSlider->setEnabled(enable && nonAuto); - myTopBorderSlider->setEnabled(enable && nonAuto); - myBtmBorderSlider->setEnabled(enable && nonAuto); + myWinLeftSlider->setEnabled(enable && nonAuto); + myWinRightSlider->setEnabled(enable && nonAuto); + myWinTopSlider->setEnabled(enable && nonAuto); + myWinBottomSlider->setEnabled(enable && nonAuto); } // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - @@ -1350,7 +1346,7 @@ void VideoAudioDialog::handleCommand(CommandSender* sender, int cmd, break; case kBezelEnableChanged: - case kAutoBordersChanged: + case kAutoWindowChanged: handleBezelChange(); break; diff --git a/src/gui/VideoAudioDialog.hxx b/src/gui/VideoAudioDialog.hxx index 4b3be0d4c..fe165619b 100644 --- a/src/gui/VideoAudioDialog.hxx +++ b/src/gui/VideoAudioDialog.hxx @@ -135,11 +135,11 @@ class VideoAudioDialog : public Dialog ButtonWidget* myOpenBrowserButton{nullptr}; EditTextWidget* myBezelPath{nullptr}; CheckboxWidget* myBezelShowWindowed{nullptr}; - CheckboxWidget* myManualBorders{nullptr}; - SliderWidget* myLeftBorderSlider{nullptr}; - SliderWidget* myRightBorderSlider{nullptr}; - SliderWidget* myTopBorderSlider{nullptr}; - SliderWidget* myBtmBorderSlider{nullptr}; + CheckboxWidget* myManualWindow{nullptr}; + SliderWidget* myWinLeftSlider{nullptr}; + SliderWidget* myWinRightSlider{nullptr}; + SliderWidget* myWinTopSlider{nullptr}; + SliderWidget* myWinBottomSlider{nullptr}; // Audio CheckboxWidget* mySoundEnableCheckbox{nullptr}; @@ -183,7 +183,7 @@ class VideoAudioDialog : public Dialog kBezelEnableChanged = 'BZen', kChooseBezelDirCmd = 'BZsl', - kAutoBordersChanged = 'BZab', + kAutoWindowChanged = 'BZab', kSoundEnableChanged = 'ADse', kDeviceChanged = 'ADdc', diff --git a/src/os/windows/Stella.vcxproj b/src/os/windows/Stella.vcxproj index 39524a5c3..b00039f86 100755 --- a/src/os/windows/Stella.vcxproj +++ b/src/os/windows/Stella.vcxproj @@ -734,6 +734,7 @@ + @@ -993,7 +994,6 @@ true - @@ -2051,6 +2051,7 @@ + @@ -2321,7 +2322,6 @@ - diff --git a/src/os/windows/Stella.vcxproj.filters b/src/os/windows/Stella.vcxproj.filters index 3874d2089..59b9fb021 100644 --- a/src/os/windows/Stella.vcxproj.filters +++ b/src/os/windows/Stella.vcxproj.filters @@ -1209,8 +1209,8 @@ Source Files\debugger\gui - - Source Files\emucore + + Source Files @@ -2468,8 +2468,8 @@ Header Files\debugger\gui - - Header Files\emucore + + Header Files