mirror of
https://github.com/HarbourMasters/Shipwright.git
synced 2025-08-22 06:13:45 -07:00
Disable "Boot Sequence" dropdown when Boot to Debug Warp Screen is enabled
This commit is contained in:
parent
1c44574e38
commit
3154dd611f
3 changed files with 11 additions and 0 deletions
|
@ -19,6 +19,7 @@ typedef enum {
|
||||||
DISABLE_FOR_FRAME_ADVANCE_OFF,
|
DISABLE_FOR_FRAME_ADVANCE_OFF,
|
||||||
DISABLE_FOR_ADVANCED_RESOLUTION_OFF,
|
DISABLE_FOR_ADVANCED_RESOLUTION_OFF,
|
||||||
DISABLE_FOR_VERTICAL_RESOLUTION_OFF,
|
DISABLE_FOR_VERTICAL_RESOLUTION_OFF,
|
||||||
|
DISABLE_FOR_BOOT_TO_DEBUG_WARP_SCREEN_ON,
|
||||||
} DisableOption;
|
} DisableOption;
|
||||||
|
|
||||||
struct WidgetInfo;
|
struct WidgetInfo;
|
||||||
|
|
|
@ -155,6 +155,12 @@ void SohMenu::InitElement() {
|
||||||
return !CVarGetInteger(CVAR_PREFIX_ADVANCED_RESOLUTION ".VerticalResolutionToggle", 0);
|
return !CVarGetInteger(CVAR_PREFIX_ADVANCED_RESOLUTION ".VerticalResolutionToggle", 0);
|
||||||
},
|
},
|
||||||
"Vertical Resolution Toggle is Off" } },
|
"Vertical Resolution Toggle is Off" } },
|
||||||
|
{ DISABLE_FOR_BOOT_TO_DEBUG_WARP_SCREEN_ON,
|
||||||
|
{ [](disabledInfo& info) -> bool {
|
||||||
|
return CVarGetInteger(CVAR_DEVELOPER_TOOLS("DebugEnabled"), 0) &&
|
||||||
|
CVarGetInteger(CVAR_DEVELOPER_TOOLS("BootToDebugWarpScreen"), 0);
|
||||||
|
},
|
||||||
|
"\"Boot To Debug Warp Screen\" Enabled (see Dev Tools -> General)" } },
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -159,6 +159,10 @@ void SohMenu::AddMenuSettings() {
|
||||||
AddWidget(path, "Boot Sequence", WIDGET_CVAR_COMBOBOX)
|
AddWidget(path, "Boot Sequence", WIDGET_CVAR_COMBOBOX)
|
||||||
.CVar(CVAR_SETTING("BootSequence"))
|
.CVar(CVAR_SETTING("BootSequence"))
|
||||||
.RaceDisable(false)
|
.RaceDisable(false)
|
||||||
|
.PreFunc([](WidgetInfo& info) {
|
||||||
|
if (mSohMenu->disabledMap.at(DISABLE_FOR_BOOT_TO_DEBUG_WARP_SCREEN_ON).active)
|
||||||
|
info.activeDisables.push_back(DISABLE_FOR_BOOT_TO_DEBUG_WARP_SCREEN_ON);
|
||||||
|
})
|
||||||
.Options(ComboboxOptions()
|
.Options(ComboboxOptions()
|
||||||
.DefaultIndex(BOOTSEQUENCE_DEFAULT)
|
.DefaultIndex(BOOTSEQUENCE_DEFAULT)
|
||||||
.LabelPosition(LabelPositions::Far)
|
.LabelPosition(LabelPositions::Far)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue