mirror of
https://github.com/RetroDECK/ES-DE.git
synced 2024-11-21 21:55:38 +00:00
Fixed multiple issues with the UI modes (full/kiosk/kid).
Also improved the quit menu.
This commit is contained in:
parent
ade0160ffe
commit
defb16b6da
|
@ -925,7 +925,6 @@ You can use `--help` or `-h` to view a list of command line options, as shown he
|
||||||
--ignore-gamelist Ignore the gamelist files (useful for troubleshooting)
|
--ignore-gamelist Ignore the gamelist files (useful for troubleshooting)
|
||||||
--show-hidden-files Show hidden files and folders
|
--show-hidden-files Show hidden files and folders
|
||||||
--show-hidden-games Show hidden games
|
--show-hidden-games Show hidden games
|
||||||
--no-exit Don't show the exit option in the menu
|
|
||||||
--no-splash Don't show the splash screen
|
--no-splash Don't show the splash screen
|
||||||
--debug Print debug information
|
--debug Print debug information
|
||||||
--windowed Windowed mode, should be combined with --resolution
|
--windowed Windowed mode, should be combined with --resolution
|
||||||
|
@ -951,7 +950,6 @@ You can use `--help` or `-h` to view a list of command line options, as shown he
|
||||||
--ignore-gamelist Ignore the gamelist files (useful for troubleshooting)
|
--ignore-gamelist Ignore the gamelist files (useful for troubleshooting)
|
||||||
--show-hidden-files Show hidden files and folders
|
--show-hidden-files Show hidden files and folders
|
||||||
--show-hidden-games Show hidden games
|
--show-hidden-games Show hidden games
|
||||||
--no-exit Don't show the exit option in the menu
|
|
||||||
--no-splash Don't show the splash screen
|
--no-splash Don't show the splash screen
|
||||||
--debug Print debug information
|
--debug Print debug information
|
||||||
--vsync [1/on or 0/off] Turn vsync on or off (default is on)
|
--vsync [1/on or 0/off] Turn vsync on or off (default is on)
|
||||||
|
@ -974,7 +972,6 @@ You can use `--help` or `-h` to view a list of command line options, as shown he
|
||||||
--ignore-gamelist Ignore the gamelist files (useful for troubleshooting)
|
--ignore-gamelist Ignore the gamelist files (useful for troubleshooting)
|
||||||
--show-hidden-files Show hidden files and folders
|
--show-hidden-files Show hidden files and folders
|
||||||
--show-hidden-games Show hidden games
|
--show-hidden-games Show hidden games
|
||||||
--no-exit Don't show the exit option in the menu
|
|
||||||
--no-splash Don't show the splash screen
|
--no-splash Don't show the splash screen
|
||||||
--debug Print debug information
|
--debug Print debug information
|
||||||
--vsync [1/on or 0/off] Turn vsync on or off (default is on)
|
--vsync [1/on or 0/off] Turn vsync on or off (default is on)
|
||||||
|
|
14
USERGUIDE.md
14
USERGUIDE.md
|
@ -690,7 +690,7 @@ The theme to use. Defaults to rbsimple-DE, the theme shipped with EmulationStati
|
||||||
|
|
||||||
**UI mode**
|
**UI mode**
|
||||||
|
|
||||||
Defaults to Full which enables all functionality within the application. If set to Kid, only games marked as being suitable for children will be displayed, and there will be an option to disable the menu. In Kiosk mode, most settings are disabled.
|
Defaults to Full which enables all functionality within the application. If set to Kid, only games marked as being suitable for children will be displayed (this flag is set manually per game using the metadata editor). Additionally, the game options menu is disabled, as well as the screensaver controls and the ability to flag games as favorites. There is also a separate option available to enable or disable the main menu when in Kid mode, see 'Enable menu in kid mode' further below. In Kiosk mode, the main menu will be available, but it will only display the entry to change the system audio volume. The game options menu will be usable, but the metadata editor and the ability to modify custom game collections will be disabled. Finally, screensaver controls will be enabled when in Kiosk mode.
|
||||||
|
|
||||||
**Default sort order**
|
**Default sort order**
|
||||||
|
|
||||||
|
@ -740,10 +740,6 @@ Activating or deactivating the built-in help systems that provides contextual in
|
||||||
|
|
||||||
Some themes (including rbsimple-DE) display the game images briefly before playing the game videos. This setting forces the videos to be played immediately, regardless of the configuration in the theme. Note though that if there is a video available for a game, but no images, the video will always start to play immediately no matter the theme configuration or whether this settings has been enabled or not.
|
Some themes (including rbsimple-DE) display the game images briefly before playing the game videos. This setting forces the videos to be played immediately, regardless of the configuration in the theme. Note though that if there is a video available for a game, but no images, the video will always start to play immediately no matter the theme configuration or whether this settings has been enabled or not.
|
||||||
|
|
||||||
**Show start menu in kid mode**
|
|
||||||
|
|
||||||
Hiding or showing the menu when the UI mode is set to Kid.
|
|
||||||
|
|
||||||
#### Screensaver settings
|
#### Screensaver settings
|
||||||
|
|
||||||
Settings for the built-in screensaver.
|
Settings for the built-in screensaver.
|
||||||
|
@ -934,13 +930,13 @@ Using this option, you can place game images and videos in the ROM directory tre
|
||||||
|
|
||||||
Displays the framerate and VRAM statistics as an overlay. You normally never need to use this. **Note:** As of version 1.0.0 the VRAM usage statistics is not accurate; this issue will be addressed in future ES-DE versions.
|
Displays the framerate and VRAM statistics as an overlay. You normally never need to use this. **Note:** As of version 1.0.0 the VRAM usage statistics is not accurate; this issue will be addressed in future ES-DE versions.
|
||||||
|
|
||||||
**Show 'Reboot System' menu entry - Unix and Windows only**
|
**Enable menu in kid mode**
|
||||||
|
|
||||||
Gives the ability to hide the "Reboot system" entry on the quit menu. Anyone who has accidentally rebooted a system from such a menu will appreciate this.
|
Enabling or disabling the menu when the UI mode is set to Kid.
|
||||||
|
|
||||||
**Show 'Power Off System' menu entry - Unix and Windows only**
|
**Show quit menu (reboot and power off entries)** _(Unix and Windows only)_
|
||||||
|
|
||||||
Gives the ability to hide the "Power off system" entry on the quit menu. Anyone who has accidentally powered off a system from such a menu will appreciate this.
|
With this setting enabled, there is a Quit menu shown as the last entry on the main menu which provides options to quit ES-DE, to reboot the computer or to power off the computer. With this setting disabled, there will simply be an entry shown to quit the application instead of the complete quit menu.
|
||||||
|
|
||||||
|
|
||||||
### Configure input
|
### Configure input
|
||||||
|
|
Binary file not shown.
|
@ -59,7 +59,6 @@ void GuiGamelistFilter::resetAllFilters()
|
||||||
std::shared_ptr<OptionListComponent<std::string>> optionList = it->second;
|
std::shared_ptr<OptionListComponent<std::string>> optionList = it->second;
|
||||||
optionList->selectNone();
|
optionList->selectNone();
|
||||||
}
|
}
|
||||||
bool testbool = mFilterIndex->isFiltered();
|
|
||||||
|
|
||||||
mFilterIndex->setTextFilter("");
|
mFilterIndex->setTextFilter("");
|
||||||
mTextFilterField->setValue("");
|
mTextFilterField->setValue("");
|
||||||
|
|
|
@ -56,7 +56,13 @@ GuiMenu::GuiMenu(Window* window) : GuiComponent(window),
|
||||||
if (isFullUI)
|
if (isFullUI)
|
||||||
addEntry("CONFIGURE INPUT", 0x777777FF, true, [this] { openConfigInput(); });
|
addEntry("CONFIGURE INPUT", 0x777777FF, true, [this] { openConfigInput(); });
|
||||||
|
|
||||||
addEntry("QUIT", 0x777777FF, true, [this] {openQuitMenu(); });
|
if (!Settings::getInstance()->getBool("ForceKiosk") &&
|
||||||
|
Settings::getInstance()->getString("UIMode") != "kiosk") {
|
||||||
|
if (Settings::getInstance()->getBool("ShowQuitMenu"))
|
||||||
|
addEntry("QUIT", 0x777777FF, true, [this] {openQuitMenu(); });
|
||||||
|
else
|
||||||
|
addEntry("QUIT", 0x777777FF, false, [this] {openQuitMenu(); });
|
||||||
|
}
|
||||||
|
|
||||||
addChild(&mMenu);
|
addChild(&mMenu);
|
||||||
addVersionInfo();
|
addVersionInfo();
|
||||||
|
@ -174,10 +180,20 @@ void GuiMenu::openUISettings()
|
||||||
uiModes.push_back("full");
|
uiModes.push_back("full");
|
||||||
uiModes.push_back("kiosk");
|
uiModes.push_back("kiosk");
|
||||||
uiModes.push_back("kid");
|
uiModes.push_back("kid");
|
||||||
|
std::string setMode;
|
||||||
|
if (Settings::getInstance()->getBool("ForceKiosk"))
|
||||||
|
setMode = "kiosk";
|
||||||
|
else if (Settings::getInstance()->getBool("ForceKid"))
|
||||||
|
setMode = "kid";
|
||||||
|
else
|
||||||
|
setMode = Settings::getInstance()->getString("UIMode");
|
||||||
for (auto it = uiModes.cbegin(); it != uiModes.cend(); it++)
|
for (auto it = uiModes.cbegin(); it != uiModes.cend(); it++)
|
||||||
ui_mode->add(*it, *it, Settings::getInstance()->getString("UIMode") == *it);
|
ui_mode->add(*it, *it, setMode == *it);
|
||||||
s->addWithLabel("UI MODE", ui_mode);
|
s->addWithLabel("UI MODE", ui_mode);
|
||||||
s->addSaveFunc([ui_mode, this, s] {
|
s->addSaveFunc([ui_mode, this, s] {
|
||||||
|
// Always save settings if mode was forced to 'full'.
|
||||||
|
if (Settings::getInstance()->getBool("ForceFull"))
|
||||||
|
s->setNeedsSaving();
|
||||||
std::string selectedMode = ui_mode->getSelected();
|
std::string selectedMode = ui_mode->getSelected();
|
||||||
if (selectedMode != Settings::getInstance()->getString("UIMode") &&
|
if (selectedMode != Settings::getInstance()->getString("UIMode") &&
|
||||||
selectedMode != "full") {
|
selectedMode != "full") {
|
||||||
|
@ -192,6 +208,9 @@ void GuiMenu::openUISettings()
|
||||||
LOG(LogDebug) << "GuiMenu::openUISettings(): Setting UI mode to '"
|
LOG(LogDebug) << "GuiMenu::openUISettings(): Setting UI mode to '"
|
||||||
<< selectedMode << "'.";
|
<< selectedMode << "'.";
|
||||||
Settings::getInstance()->setString("UIMode", selectedMode);
|
Settings::getInstance()->setString("UIMode", selectedMode);
|
||||||
|
Settings::getInstance()->setBool("ForceFull", false);
|
||||||
|
Settings::getInstance()->setBool("ForceKiosk", false);
|
||||||
|
Settings::getInstance()->setBool("ForceKid", false);
|
||||||
Settings::getInstance()->saveFile();
|
Settings::getInstance()->saveFile();
|
||||||
}, "NO", nullptr));
|
}, "NO", nullptr));
|
||||||
}
|
}
|
||||||
|
@ -200,6 +219,9 @@ void GuiMenu::openUISettings()
|
||||||
LOG(LogDebug) << "GuiMenu::openUISettings(): Setting UI mode to '" <<
|
LOG(LogDebug) << "GuiMenu::openUISettings(): Setting UI mode to '" <<
|
||||||
selectedMode << "'.";
|
selectedMode << "'.";
|
||||||
Settings::getInstance()->setString("UIMode", ui_mode->getSelected());
|
Settings::getInstance()->setString("UIMode", ui_mode->getSelected());
|
||||||
|
Settings::getInstance()->setBool("ForceFull", false);
|
||||||
|
Settings::getInstance()->setBool("ForceKiosk", false);
|
||||||
|
Settings::getInstance()->setBool("ForceKid", false);
|
||||||
s->setNeedsSaving();
|
s->setNeedsSaving();
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
@ -388,18 +410,6 @@ void GuiMenu::openUISettings()
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
// Whether to show start menu in Kid mode.
|
|
||||||
auto show_kid_start_menu = std::make_shared<SwitchComponent>(mWindow);
|
|
||||||
show_kid_start_menu->setState(Settings::getInstance()->getBool("ShowKidStartMenu"));
|
|
||||||
s->addWithLabel("SHOW START MENU IN KID MODE", show_kid_start_menu);
|
|
||||||
s->addSaveFunc([show_kid_start_menu, s] {
|
|
||||||
if (Settings::getInstance()->getBool("ShowKidStartMenu") !=
|
|
||||||
show_kid_start_menu->getState()) {
|
|
||||||
Settings::getInstance()->setBool("ShowKidStartMenu", show_kid_start_menu->getState());
|
|
||||||
s->setNeedsSaving();
|
|
||||||
}
|
|
||||||
});
|
|
||||||
|
|
||||||
// Screensaver.
|
// Screensaver.
|
||||||
ComponentListRow screensaver_row;
|
ComponentListRow screensaver_row;
|
||||||
screensaver_row.elements.clear();
|
screensaver_row.elements.clear();
|
||||||
|
@ -808,30 +818,31 @@ void GuiMenu::openOtherSettings()
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
// macOS requires root privileges to reboot and power off so it doesn't make much
|
// Whether to enable the menu in Kid mode.
|
||||||
// sense to enable these settings and menu entries for this operating system.
|
auto enable_menu_kid_mode = std::make_shared<SwitchComponent>(mWindow);
|
||||||
#if !defined(__APPLE__)
|
enable_menu_kid_mode->setState(Settings::getInstance()->getBool("EnableMenuKidMode"));
|
||||||
// Hide Reboot System option in the quit menu.
|
s->addWithLabel("ENABLE MENU IN KID MODE", enable_menu_kid_mode);
|
||||||
auto show_reboot_system = std::make_shared<SwitchComponent>(mWindow);
|
s->addSaveFunc([enable_menu_kid_mode, s] {
|
||||||
show_reboot_system->setState(Settings::getInstance()->getBool("ShowRebootSystem"));
|
if (Settings::getInstance()->getBool("EnableMenuKidMode") !=
|
||||||
s->addWithLabel("SHOW 'REBOOT SYSTEM' MENU ENTRY", show_reboot_system);
|
enable_menu_kid_mode->getState()) {
|
||||||
s->addSaveFunc([show_reboot_system, s] {
|
Settings::getInstance()->setBool("EnableMenuKidMode", enable_menu_kid_mode->getState());
|
||||||
if (show_reboot_system->getState() !=
|
s->setNeedsSaving();
|
||||||
Settings::getInstance()->getBool("ShowRebootSystem")) {
|
|
||||||
Settings::getInstance()->setBool("ShowRebootSystem", show_reboot_system->getState());
|
|
||||||
s->setNeedsSaving();
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
// Hide Power Off System option in the quit menu.
|
// macOS requires root privileges to reboot and power off so it doesn't make much
|
||||||
auto show_poweroff_system = std::make_shared<SwitchComponent>(mWindow);
|
// sense to show the quit menu for this operating system.
|
||||||
show_poweroff_system->setState(Settings::getInstance()->getBool("ShowPoweroffSystem"));
|
#if !defined(__APPLE__)
|
||||||
s->addWithLabel("SHOW 'POWER OFF SYSTEM' MENU ENTRY", show_poweroff_system);
|
// Whether to show the quit menu with the options to reboot and shutdown the computer.
|
||||||
s->addSaveFunc([show_poweroff_system, s] {
|
auto show_quit_menu = std::make_shared<SwitchComponent>(mWindow);
|
||||||
if (show_poweroff_system->getState() !=
|
show_quit_menu->setState(Settings::getInstance()->getBool("ShowQuitMenu"));
|
||||||
Settings::getInstance()->getBool("ShowPoweroffSystem")) {
|
s->addWithLabel("SHOW QUIT MENU (REBOOT AND POWER OFF ENTRIES)", show_quit_menu);
|
||||||
Settings::getInstance()->setBool("ShowPoweroffSystem", show_poweroff_system->getState());
|
s->addSaveFunc([this, show_quit_menu, s] {
|
||||||
s->setNeedsSaving();
|
if (show_quit_menu->getState() !=
|
||||||
|
Settings::getInstance()->getBool("ShowQuitMenu")) {
|
||||||
|
Settings::getInstance()->setBool("ShowQuitMenu", show_quit_menu->getState());
|
||||||
|
s->setNeedsSaving();
|
||||||
|
GuiMenu::close(false);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
#endif
|
#endif
|
||||||
|
@ -851,31 +862,40 @@ void GuiMenu::openConfigInput()
|
||||||
|
|
||||||
void GuiMenu::openQuitMenu()
|
void GuiMenu::openQuitMenu()
|
||||||
{
|
{
|
||||||
auto s = new GuiSettings(mWindow, "QUIT");
|
if (!Settings::getInstance()->getBool("ShowQuitMenu")) {
|
||||||
|
mWindow->pushGui(new GuiMsgBox(mWindow, this->getHelpStyle(),
|
||||||
Window* window = mWindow;
|
"REALLY QUIT?", "YES", [this] {
|
||||||
HelpStyle style = getHelpStyle();
|
Scripting::fireEvent("quit");
|
||||||
|
close(true);
|
||||||
ComponentListRow row;
|
quitES();
|
||||||
if (UIModeController::getInstance()->isUIModeFull()) {
|
}, "NO", nullptr));
|
||||||
if (Settings::getInstance()->getBool("ShowExit")) {
|
|
||||||
row.makeAcceptInputHandler([window, this] {
|
|
||||||
window->pushGui(new GuiMsgBox(window, this->getHelpStyle(),
|
|
||||||
"REALLY QUIT?", "YES", [] {
|
|
||||||
Scripting::fireEvent("quit");
|
|
||||||
quitES();
|
|
||||||
}, "NO", nullptr));
|
|
||||||
});
|
|
||||||
row.addElement(std::make_shared<TextComponent>(window, "QUIT EMULATIONSTATION",
|
|
||||||
Font::get(FONT_SIZE_MEDIUM), 0x777777FF), true);
|
|
||||||
s->addRow(row);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
else {
|
||||||
|
auto s = new GuiSettings(mWindow, "QUIT");
|
||||||
|
|
||||||
|
Window* window = mWindow;
|
||||||
|
HelpStyle style = getHelpStyle();
|
||||||
|
|
||||||
|
// This transparent bracket is only neeeded to generate the correct help prompts.
|
||||||
|
auto bracket = std::make_shared<ImageComponent>(mWindow);
|
||||||
|
bracket->setImage(":/graphics/arrow.svg");
|
||||||
|
bracket->setOpacity(0);
|
||||||
|
|
||||||
|
ComponentListRow row;
|
||||||
|
|
||||||
|
row.makeAcceptInputHandler([window, this] {
|
||||||
|
window->pushGui(new GuiMsgBox(window, this->getHelpStyle(),
|
||||||
|
"REALLY QUIT?", "YES", [this] {
|
||||||
|
Scripting::fireEvent("quit");
|
||||||
|
close(true);
|
||||||
|
quitES();
|
||||||
|
}, "NO", nullptr));
|
||||||
|
});
|
||||||
|
row.addElement(std::make_shared<TextComponent>(window, "QUIT EMULATIONSTATION",
|
||||||
|
Font::get(FONT_SIZE_MEDIUM), 0x777777FF), true);
|
||||||
|
row.addElement(bracket, false);
|
||||||
|
s->addRow(row);
|
||||||
|
|
||||||
// macOS requires root privileges to reboot and power off so it doesn't make much
|
|
||||||
// sense to enable these settings and menu entries for this operating system.
|
|
||||||
#if !defined(__APPLE__)
|
|
||||||
if (Settings::getInstance()->getBool("ShowRebootSystem")) {
|
|
||||||
row.elements.clear();
|
row.elements.clear();
|
||||||
row.makeAcceptInputHandler([window, this] {
|
row.makeAcceptInputHandler([window, this] {
|
||||||
window->pushGui(new GuiMsgBox(window, this->getHelpStyle(),
|
window->pushGui(new GuiMsgBox(window, this->getHelpStyle(),
|
||||||
|
@ -889,10 +909,9 @@ void GuiMenu::openQuitMenu()
|
||||||
});
|
});
|
||||||
row.addElement(std::make_shared<TextComponent>(window, "REBOOT SYSTEM",
|
row.addElement(std::make_shared<TextComponent>(window, "REBOOT SYSTEM",
|
||||||
Font::get(FONT_SIZE_MEDIUM), 0x777777FF), true);
|
Font::get(FONT_SIZE_MEDIUM), 0x777777FF), true);
|
||||||
|
row.addElement(bracket, false);
|
||||||
s->addRow(row);
|
s->addRow(row);
|
||||||
}
|
|
||||||
|
|
||||||
if (Settings::getInstance()->getBool("ShowPoweroffSystem")) {
|
|
||||||
row.elements.clear();
|
row.elements.clear();
|
||||||
row.makeAcceptInputHandler([window, this] {
|
row.makeAcceptInputHandler([window, this] {
|
||||||
window->pushGui(new GuiMsgBox(window, this->getHelpStyle(),
|
window->pushGui(new GuiMsgBox(window, this->getHelpStyle(),
|
||||||
|
@ -906,11 +925,11 @@ void GuiMenu::openQuitMenu()
|
||||||
});
|
});
|
||||||
row.addElement(std::make_shared<TextComponent>(window, "POWER OFF SYSTEM",
|
row.addElement(std::make_shared<TextComponent>(window, "POWER OFF SYSTEM",
|
||||||
Font::get(FONT_SIZE_MEDIUM), 0x777777FF), true);
|
Font::get(FONT_SIZE_MEDIUM), 0x777777FF), true);
|
||||||
|
row.addElement(bracket, false);
|
||||||
s->addRow(row);
|
s->addRow(row);
|
||||||
}
|
|
||||||
#endif
|
|
||||||
|
|
||||||
mWindow->pushGui(s);
|
mWindow->pushGui(s);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void GuiMenu::addVersionInfo()
|
void GuiMenu::addVersionInfo()
|
||||||
|
|
|
@ -243,9 +243,6 @@ bool parseArgs(int argc, char* argv[])
|
||||||
else if (strcmp(argv[i], "--show-hidden-games") == 0) {
|
else if (strcmp(argv[i], "--show-hidden-games") == 0) {
|
||||||
Settings::getInstance()->setBool("ShowHiddenGames", true);
|
Settings::getInstance()->setBool("ShowHiddenGames", true);
|
||||||
}
|
}
|
||||||
else if (strcmp(argv[i], "--no-exit") == 0) {
|
|
||||||
Settings::getInstance()->setBool("ShowExit", false);
|
|
||||||
}
|
|
||||||
else if (strcmp(argv[i], "--no-splash") == 0) {
|
else if (strcmp(argv[i], "--no-splash") == 0) {
|
||||||
Settings::getInstance()->setBool("SplashScreen", false);
|
Settings::getInstance()->setBool("SplashScreen", false);
|
||||||
}
|
}
|
||||||
|
@ -277,6 +274,7 @@ bool parseArgs(int argc, char* argv[])
|
||||||
}
|
}
|
||||||
else if (strcmp(argv[i], "--force-full") == 0) {
|
else if (strcmp(argv[i], "--force-full") == 0) {
|
||||||
Settings::getInstance()->setString("UIMode", "full");
|
Settings::getInstance()->setString("UIMode", "full");
|
||||||
|
Settings::getInstance()->setBool("ForceFull", true);
|
||||||
}
|
}
|
||||||
else if (strcmp(argv[i], "--force-kiosk") == 0) {
|
else if (strcmp(argv[i], "--force-kiosk") == 0) {
|
||||||
Settings::getInstance()->setBool("ForceKiosk", true);
|
Settings::getInstance()->setBool("ForceKiosk", true);
|
||||||
|
@ -302,7 +300,6 @@ bool parseArgs(int argc, char* argv[])
|
||||||
" --ignore-gamelist Ignore the gamelist files (useful for troubleshooting)\n"
|
" --ignore-gamelist Ignore the gamelist files (useful for troubleshooting)\n"
|
||||||
" --show-hidden-files Show hidden files and folders\n"
|
" --show-hidden-files Show hidden files and folders\n"
|
||||||
" --show-hidden-games Show hidden games\n"
|
" --show-hidden-games Show hidden games\n"
|
||||||
" --no-exit Don't show the exit option in the menu\n"
|
|
||||||
" --no-splash Don't show the splash screen\n"
|
" --no-splash Don't show the splash screen\n"
|
||||||
" --debug Print debug information\n"
|
" --debug Print debug information\n"
|
||||||
#if defined(__unix__)
|
#if defined(__unix__)
|
||||||
|
|
|
@ -81,7 +81,9 @@ void UIModeController::unlockUIMode()
|
||||||
|
|
||||||
bool UIModeController::isUIModeFull()
|
bool UIModeController::isUIModeFull()
|
||||||
{
|
{
|
||||||
return ((mCurrentUIMode == "full") && !Settings::getInstance()->getBool("ForceKiosk"));
|
return ((mCurrentUIMode == "full" || (isUIModeKid() &&
|
||||||
|
Settings::getInstance()->getBool("EnableMenuKidMode")))
|
||||||
|
&& !Settings::getInstance()->getBool("ForceKiosk"));
|
||||||
}
|
}
|
||||||
|
|
||||||
bool UIModeController::isUIModeKid()
|
bool UIModeController::isUIModeKid()
|
||||||
|
|
|
@ -630,7 +630,7 @@ bool ViewController::input(InputConfig* config, Input input)
|
||||||
|
|
||||||
// Open the main menu.
|
// Open the main menu.
|
||||||
if (!(UIModeController::getInstance()->isUIModeKid() &&
|
if (!(UIModeController::getInstance()->isUIModeKid() &&
|
||||||
!Settings::getInstance()->getBool("ShowKidStartMenu")) &&
|
!Settings::getInstance()->getBool("EnableMenuKidMode")) &&
|
||||||
config->isMappedTo("start", input) && input.value != 0) {
|
config->isMappedTo("start", input) && input.value != 0) {
|
||||||
// If we don't stop the scrolling here, it will continue to
|
// If we don't stop the scrolling here, it will continue to
|
||||||
// run after closing the menu.
|
// run after closing the menu.
|
||||||
|
@ -833,7 +833,7 @@ std::vector<HelpPrompt> ViewController::getHelpPrompts()
|
||||||
|
|
||||||
prompts = mCurrentView->getHelpPrompts();
|
prompts = mCurrentView->getHelpPrompts();
|
||||||
if (!(UIModeController::getInstance()->isUIModeKid() &&
|
if (!(UIModeController::getInstance()->isUIModeKid() &&
|
||||||
!Settings::getInstance()->getBool("ShowKidStartMenu")))
|
!Settings::getInstance()->getBool("EnableMenuKidMode")))
|
||||||
prompts.push_back(HelpPrompt("start", "menu"));
|
prompts.push_back(HelpPrompt("start", "menu"));
|
||||||
return prompts;
|
return prompts;
|
||||||
}
|
}
|
||||||
|
|
|
@ -28,10 +28,10 @@ Settings* Settings::sInstance = nullptr;
|
||||||
std::vector<std::string> settings_dont_save {
|
std::vector<std::string> settings_dont_save {
|
||||||
// These options can be set using command-line arguments:
|
// These options can be set using command-line arguments:
|
||||||
"Debug", // --debug
|
"Debug", // --debug
|
||||||
|
"ForceFull", // --force-full
|
||||||
"ForceKid", // --force-kid
|
"ForceKid", // --force-kid
|
||||||
"ForceKiosk", // --force-kiosk
|
"ForceKiosk", // --force-kiosk
|
||||||
"IgnoreGamelist", // --ignore-gamelist
|
"IgnoreGamelist", // --ignore-gamelist
|
||||||
"ShowExit", // --no-exit
|
|
||||||
"SplashScreen", // --no-splash
|
"SplashScreen", // --no-splash
|
||||||
"VSync", // --vsync [1/on or 0/off]
|
"VSync", // --vsync [1/on or 0/off]
|
||||||
#if !defined(_WIN64)
|
#if !defined(_WIN64)
|
||||||
|
@ -124,7 +124,7 @@ void Settings::setDefaults()
|
||||||
mBoolMap["QuickSystemSelect"] = { true, true };
|
mBoolMap["QuickSystemSelect"] = { true, true };
|
||||||
mBoolMap["ShowHelpPrompts"] = { true, true };
|
mBoolMap["ShowHelpPrompts"] = { true, true };
|
||||||
mBoolMap["PlayVideosImmediately"] = { false, false };
|
mBoolMap["PlayVideosImmediately"] = { false, false };
|
||||||
mBoolMap["ShowKidStartMenu"] = { false, false };
|
mBoolMap["EnableMenuKidMode"] = { false, false };
|
||||||
|
|
||||||
// UI settings -> screensaver settings.
|
// UI settings -> screensaver settings.
|
||||||
mIntMap["ScreensaverTimer"] = { 5*60*1000, 5*60*1000 }; // 5 minutes
|
mIntMap["ScreensaverTimer"] = { 5*60*1000, 5*60*1000 }; // 5 minutes
|
||||||
|
@ -226,9 +226,10 @@ void Settings::setDefaults()
|
||||||
mBoolMap["DisplayGPUStatistics"] = { false, false };
|
mBoolMap["DisplayGPUStatistics"] = { false, false };
|
||||||
// macOS requires root privileges to reboot and power off so it doesn't make much
|
// macOS requires root privileges to reboot and power off so it doesn't make much
|
||||||
// sense to enable these settings and menu entries for this operating system.
|
// sense to enable these settings and menu entries for this operating system.
|
||||||
#if !defined(__APPLE__)
|
#if defined(__APPLE__)
|
||||||
mBoolMap["ShowRebootSystem"] = { true, true };
|
mBoolMap["ShowQuitMenu"] = { false, false };
|
||||||
mBoolMap["ShowPoweroffSystem"] = { true, true };
|
#else
|
||||||
|
mBoolMap["ShowQuitMenu"] = { true, true };
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
//
|
//
|
||||||
|
@ -237,10 +238,10 @@ void Settings::setDefaults()
|
||||||
|
|
||||||
// Options listed using --help
|
// Options listed using --help
|
||||||
mBoolMap["Debug"] = { false, false };
|
mBoolMap["Debug"] = { false, false };
|
||||||
|
mBoolMap["ForceFull"] = { false, false };
|
||||||
mBoolMap["ForceKid"] = { false, false };
|
mBoolMap["ForceKid"] = { false, false };
|
||||||
mBoolMap["ForceKiosk"] = { false, false };
|
mBoolMap["ForceKiosk"] = { false, false };
|
||||||
mBoolMap["IgnoreGamelist"] = { false, false };
|
mBoolMap["IgnoreGamelist"] = { false, false };
|
||||||
mBoolMap["ShowExit"] = { true, true };
|
|
||||||
mBoolMap["SplashScreen"] = { true, true };
|
mBoolMap["SplashScreen"] = { true, true };
|
||||||
mBoolMap["VSync"] = { true, true };
|
mBoolMap["VSync"] = { true, true };
|
||||||
#if !defined(_WIN64)
|
#if !defined(_WIN64)
|
||||||
|
|
Loading…
Reference in a new issue