Compare commits

...

2 Commits

Author SHA1 Message Date
Weiran Wu 8aac041694
Merge 845cdb5c0e into 215e3c5ae9 2024-03-06 11:14:14 +00:00
wuweiran 845cdb5c0e Revert name and order change of configs 2024-03-06 19:14:02 +08:00
7 changed files with 63 additions and 63 deletions

View File

@ -8,7 +8,7 @@ msgid ""
msgstr "" msgstr ""
"Project-Id-Version: PACKAGE VERSION\n" "Project-Id-Version: PACKAGE VERSION\n"
"Report-Msgid-Bugs-To: \n" "Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2024-03-05 21:49+0800\n" "POT-Creation-Date: 2024-03-06 18:49+0800\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n" "Language-Team: LANGUAGE <LL@li.org>\n"
@ -581,7 +581,7 @@ msgid ""
"along with this program. If not, see http://www.gnu.org/licenses ." "along with this program. If not, see http://www.gnu.org/licenses ."
msgstr "" msgstr ""
#: cmdevents.cpp:2495 #: cmdevents.cpp:2500
msgid "Cannot use Game Boy BIOS when Colorizer Hack is enabled." msgid "Cannot use Game Boy BIOS when Colorizer Hack is enabled."
msgstr "" msgstr ""
@ -1059,10 +1059,14 @@ msgid ""
msgstr "" msgstr ""
#: config/internal/option-internal.cpp:467 #: config/internal/option-internal.cpp:467
msgid "Enable status bar"
msgstr ""
#: config/internal/option-internal.cpp:468
msgid "INI file version (DO NOT MODIFY)" msgid "INI file version (DO NOT MODIFY)"
msgstr "" msgstr ""
#: config/internal/option-internal.cpp:471 #: config/internal/option-internal.cpp:472
msgid "" msgid ""
"The parameter Joypad/<n>/<button> contains a comma-separated list of key " "The parameter Joypad/<n>/<button> contains a comma-separated list of key "
"names which map to joypad #<n> button <button>. Button is one of Up, Down, " "names which map to joypad #<n> button <button>. Button is one of Up, Down, "
@ -1070,185 +1074,181 @@ msgid ""
"MotionRight, AutoA, AutoB, Speed, Capture, GS" "MotionRight, AutoA, AutoB, Speed, Capture, GS"
msgstr "" msgstr ""
#: config/internal/option-internal.cpp:477 #: config/internal/option-internal.cpp:478
msgid "The autofire toggle period, in frames (1/60 s)" msgid "The autofire toggle period, in frames (1/60 s)"
msgstr "" msgstr ""
#: config/internal/option-internal.cpp:479 #: config/internal/option-internal.cpp:480
msgid "The number of the stick to use in single-player mode" msgid "The number of the stick to use in single-player mode"
msgstr "" msgstr ""
#: config/internal/option-internal.cpp:483 #: config/internal/option-internal.cpp:484
msgid "" msgid ""
"The parameter Keyboard/<cmd> contains a comma-separated list of key names (e." "The parameter Keyboard/<cmd> contains a comma-separated list of key names (e."
"g. Alt-Shift-F1). When the named key is pressed, the command <cmd> is " "g. Alt-Shift-F1). When the named key is pressed, the command <cmd> is "
"executed." "executed."
msgstr "" msgstr ""
#: config/internal/option-internal.cpp:489 #: config/internal/option-internal.cpp:490
msgid "Enable AGB debug print" msgid "Enable AGB debug print"
msgstr "" msgstr ""
#: config/internal/option-internal.cpp:491 #: config/internal/option-internal.cpp:492
msgid "Auto skip frames" msgid "Auto skip frames"
msgstr "" msgstr ""
#: config/internal/option-internal.cpp:493 #: config/internal/option-internal.cpp:494
msgid "Apply IPS / UPS / IPF patches if found" msgid "Apply IPS / UPS / IPF patches if found"
msgstr "" msgstr ""
#: config/internal/option-internal.cpp:495 #: config/internal/option-internal.cpp:496
msgid "Automatically save and load cheat list" msgid "Automatically save and load cheat list"
msgstr "" msgstr ""
#: config/internal/option-internal.cpp:499 #: config/internal/option-internal.cpp:500
msgid "Automatically enable border for Super Game Boy games" msgid "Automatically enable border for Super Game Boy games"
msgstr "" msgstr ""
#: config/internal/option-internal.cpp:501 #: config/internal/option-internal.cpp:502
msgid "Always enable border" msgid "Always enable border"
msgstr "" msgstr ""
#: config/internal/option-internal.cpp:503 #: config/internal/option-internal.cpp:504
msgid "Screen capture file format" msgid "Screen capture file format"
msgstr "" msgstr ""
#: config/internal/option-internal.cpp:504 #: config/internal/option-internal.cpp:505
msgid "Enable cheats" msgid "Enable cheats"
msgstr "" msgstr ""
#: config/internal/option-internal.cpp:506 #: config/internal/option-internal.cpp:507
msgid "Disable on-screen status messages" msgid "Disable on-screen status messages"
msgstr "" msgstr ""
#: config/internal/option-internal.cpp:507 #: config/internal/option-internal.cpp:508
msgid "Type of system to emulate" msgid "Type of system to emulate"
msgstr "" msgstr ""
#: config/internal/option-internal.cpp:509 #: config/internal/option-internal.cpp:510
msgid "Flash size 0 = 64 KB 1 = 128 KB" msgid "Flash size 0 = 64 KB 1 = 128 KB"
msgstr "" msgstr ""
#: config/internal/option-internal.cpp:511 #: config/internal/option-internal.cpp:512
msgid "Skip frames. Values are 0-9 or -1 to skip automatically based on time." msgid "Skip frames. Values are 0-9 or -1 to skip automatically based on time."
msgstr "" msgstr ""
#: config/internal/option-internal.cpp:513 #: config/internal/option-internal.cpp:514
msgid "The palette to use" msgid "The palette to use"
msgstr "" msgstr ""
#: config/internal/option-internal.cpp:515 #: config/internal/option-internal.cpp:516
msgid "Enable printer emulation" msgid "Enable printer emulation"
msgstr "" msgstr ""
#: config/internal/option-internal.cpp:517 #: config/internal/option-internal.cpp:518
msgid "Break into GDB after loading the game." msgid "Break into GDB after loading the game."
msgstr "" msgstr ""
#: config/internal/option-internal.cpp:519 #: config/internal/option-internal.cpp:520
msgid "Port to connect GDB to" msgid "Port to connect GDB to"
msgstr "" msgstr ""
#: config/internal/option-internal.cpp:522 #: config/internal/option-internal.cpp:523
msgid "Number of players in network" msgid "Number of players in network"
msgstr "" msgstr ""
#: config/internal/option-internal.cpp:525 #: config/internal/option-internal.cpp:526
msgid "Maximum scale factor (0 = no limit)" msgid "Maximum scale factor (0 = no limit)"
msgstr "" msgstr ""
#: config/internal/option-internal.cpp:527 #: config/internal/option-internal.cpp:528
msgid "Pause game when main window loses focus" msgid "Pause game when main window loses focus"
msgstr "" msgstr ""
#: config/internal/option-internal.cpp:529 #: config/internal/option-internal.cpp:530
msgid "Enable RTC (vba-over.ini override is rtcEnabled" msgid "Enable RTC (vba-over.ini override is rtcEnabled"
msgstr "" msgstr ""
#: config/internal/option-internal.cpp:531 #: config/internal/option-internal.cpp:532
msgid "Native save (\"battery\") hardware type" msgid "Native save (\"battery\") hardware type"
msgstr "" msgstr ""
#: config/internal/option-internal.cpp:532 #: config/internal/option-internal.cpp:533
msgid "Show speed indicator" msgid "Show speed indicator"
msgstr "" msgstr ""
#: config/internal/option-internal.cpp:534 #: config/internal/option-internal.cpp:535
msgid "Draw on-screen messages transparently" msgid "Draw on-screen messages transparently"
msgstr "" msgstr ""
#: config/internal/option-internal.cpp:536 #: config/internal/option-internal.cpp:537
msgid "Skip BIOS initialization" msgid "Skip BIOS initialization"
msgstr "" msgstr ""
#: config/internal/option-internal.cpp:538 #: config/internal/option-internal.cpp:539
msgid "Do not overwrite cheat list when loading state" msgid "Do not overwrite cheat list when loading state"
msgstr "" msgstr ""
#: config/internal/option-internal.cpp:540 #: config/internal/option-internal.cpp:541
msgid "Do not overwrite native (battery) save when loading state" msgid "Do not overwrite native (battery) save when loading state"
msgstr "" msgstr ""
#: config/internal/option-internal.cpp:542 #: config/internal/option-internal.cpp:543
msgid "Throttle game speed, even when accelerated (0-450 %, 0 = no throttle)" msgid "Throttle game speed, even when accelerated (0-450 %, 0 = no throttle)"
msgstr "" msgstr ""
#: config/internal/option-internal.cpp:545 #: config/internal/option-internal.cpp:546
msgid "Set throttle for speedup key (0-3000 %, 0 = no throttle)" msgid "Set throttle for speedup key (0-3000 %, 0 = no throttle)"
msgstr "" msgstr ""
#: config/internal/option-internal.cpp:547 #: config/internal/option-internal.cpp:548
msgid "Number of frames to skip with speedup (instead of speedup throttle)" msgid "Number of frames to skip with speedup (instead of speedup throttle)"
msgstr "" msgstr ""
#: config/internal/option-internal.cpp:550 #: config/internal/option-internal.cpp:551
msgid "Use frame skip for speedup throttle" msgid "Use frame skip for speedup throttle"
msgstr "" msgstr ""
#: config/internal/option-internal.cpp:552 #: config/internal/option-internal.cpp:553
msgid "Use the specified BIOS file for Game Boy" msgid "Use the specified BIOS file for Game Boy"
msgstr "" msgstr ""
#: config/internal/option-internal.cpp:554 #: config/internal/option-internal.cpp:555
msgid "Use the specified BIOS file" msgid "Use the specified BIOS file"
msgstr "" msgstr ""
#: config/internal/option-internal.cpp:556 #: config/internal/option-internal.cpp:557
msgid "Use the specified BIOS file for Game Boy Color" msgid "Use the specified BIOS file for Game Boy Color"
msgstr "" msgstr ""
#: config/internal/option-internal.cpp:557 #: config/internal/option-internal.cpp:558
msgid "Wait for vertical sync" msgid "Wait for vertical sync"
msgstr "" msgstr ""
#: config/internal/option-internal.cpp:561 #: config/internal/option-internal.cpp:562
msgid "Enter fullscreen mode at startup" msgid "Enter fullscreen mode at startup"
msgstr "" msgstr ""
#: config/internal/option-internal.cpp:562 #: config/internal/option-internal.cpp:563
msgid "Window maximized" msgid "Window maximized"
msgstr "" msgstr ""
#: config/internal/option-internal.cpp:564 #: config/internal/option-internal.cpp:565
msgid "Window height at startup" msgid "Window height at startup"
msgstr "" msgstr ""
#: config/internal/option-internal.cpp:565 #: config/internal/option-internal.cpp:566
msgid "Window width at startup" msgid "Window width at startup"
msgstr "" msgstr ""
#: config/internal/option-internal.cpp:566 #: config/internal/option-internal.cpp:567
msgid "Window axis X position at startup" msgid "Window axis X position at startup"
msgstr "" msgstr ""
#: config/internal/option-internal.cpp:567 #: config/internal/option-internal.cpp:568
msgid "Window axis Y position at startup" msgid "Window axis Y position at startup"
msgstr "" msgstr ""
#: config/internal/option-internal.cpp:570
msgid "Enable status bar"
msgstr ""
#: config/internal/option-internal.cpp:573 #: config/internal/option-internal.cpp:573
msgid "Capture key events while on background" msgid "Capture key events while on background"
msgstr "" msgstr ""

View File

@ -2447,6 +2447,11 @@ EVT_HANDLER(KeepOnTop, "Keep window on top")
GetMenuOptionConfig("KeepOnTop", config::OptionID::kDispKeepOnTop); GetMenuOptionConfig("KeepOnTop", config::OptionID::kDispKeepOnTop);
} }
EVT_HANDLER(StatusBar, "Enable status bar")
{
GetMenuOptionConfig("StatusBar", config::OptionID::kGenStatusBar);
}
EVT_HANDLER(NoStatusMsg, "Disable on-screen status messages") EVT_HANDLER(NoStatusMsg, "Disable on-screen status messages")
{ {
GetMenuOptionConfig("NoStatusMsg", config::OptionID::kPrefDisableStatus); GetMenuOptionConfig("NoStatusMsg", config::OptionID::kPrefDisableStatus);
@ -2508,11 +2513,6 @@ EVT_HANDLER(VSync, "Wait for vertical sync")
GetMenuOptionConfig("VSync", config::OptionID::kPrefVsync); GetMenuOptionConfig("VSync", config::OptionID::kPrefVsync);
} }
EVT_HANDLER(EnableStatusBar, "Enable status bar")
{
GetMenuOptionConfig("EnableStatusBar", config::OptionID::kUIEnableStatusBar);
}
EVT_HANDLER(HideMenuBar, "Hide menu bar when mouse is inactive") EVT_HANDLER(HideMenuBar, "Hide menu bar when mouse is inactive")
{ {
GetMenuOptionConfig("HideMenuBar", config::OptionID::kUIHideMenuBar); GetMenuOptionConfig("HideMenuBar", config::OptionID::kUIHideMenuBar);

View File

@ -286,6 +286,7 @@ std::array<Option, kNbOptions>& Option::All() {
Option(OptionID::kGenRewindInterval, &gopts.rewind_interval, 0, 600), Option(OptionID::kGenRewindInterval, &gopts.rewind_interval, 0, 600),
Option(OptionID::kGenScreenshotDir, &g_owned_opts.screenshot_dir), Option(OptionID::kGenScreenshotDir, &g_owned_opts.screenshot_dir),
Option(OptionID::kGenStateDir, &g_owned_opts.state_dir), Option(OptionID::kGenStateDir, &g_owned_opts.state_dir),
Option(OptionID::kGenStatusBar, &g_owned_opts.statusbar),
Option(OptionID::kGenIniVersion, &g_owned_opts.ini_version, 0, std::numeric_limits<uint32_t>::max()), Option(OptionID::kGenIniVersion, &g_owned_opts.ini_version, 0, std::numeric_limits<uint32_t>::max()),
/// Joypad /// Joypad
@ -343,7 +344,6 @@ std::array<Option, kNbOptions>& Option::All() {
Option(OptionID::kGeomWindowY, &g_owned_opts.window_pos_y, std::numeric_limits<int32_t>::min(), std::numeric_limits<int32_t>::max()), Option(OptionID::kGeomWindowY, &g_owned_opts.window_pos_y, std::numeric_limits<int32_t>::min(), std::numeric_limits<int32_t>::max()),
/// UI /// UI
Option(OptionID::kUIEnableStatusBar, &g_owned_opts.statusbar),
Option(OptionID::kUIAllowKeyboardBackgroundInput, &g_owned_opts.allow_keyboard_background_input), Option(OptionID::kUIAllowKeyboardBackgroundInput, &g_owned_opts.allow_keyboard_background_input),
Option(OptionID::kUIAllowJoystickBackgroundInput, &g_owned_opts.allow_joystick_background_input), Option(OptionID::kUIAllowJoystickBackgroundInput, &g_owned_opts.allow_joystick_background_input),
Option(OptionID::kUIHideMenuBar, &gopts.hide_menu_bar), Option(OptionID::kUIHideMenuBar, &gopts.hide_menu_bar),
@ -464,6 +464,7 @@ const std::array<OptionData, kNbOptions + 1> kAllOptionsData = {
OptionData{"General/StateDir", "", OptionData{"General/StateDir", "",
_("Directory to store saved state files (relative paths are " _("Directory to store saved state files (relative paths are "
"relative to BatteryDir)")}, "relative to BatteryDir)")},
OptionData{"General/StatusBar", "StatusBar", _("Enable status bar")},
OptionData{"General/IniVersion", "", _("INI file version (DO NOT MODIFY)")}, OptionData{"General/IniVersion", "", _("INI file version (DO NOT MODIFY)")},
/// Joypad /// Joypad
@ -567,7 +568,6 @@ const std::array<OptionData, kNbOptions + 1> kAllOptionsData = {
OptionData{"geometry/windowY", "Y", _("Window axis Y position at startup")}, OptionData{"geometry/windowY", "Y", _("Window axis Y position at startup")},
/// UI /// UI
OptionData{"ui/enableStatusBar", "EnableStatusBar", _("Enable status bar")},
OptionData{"ui/allowKeyboardBackgroundInput", OptionData{"ui/allowKeyboardBackgroundInput",
"AllowKeyboardBackgroundInput", "AllowKeyboardBackgroundInput",
_("Capture key events while on background")}, _("Capture key events while on background")},

View File

@ -54,6 +54,7 @@ enum class OptionID {
kGenRewindInterval, kGenRewindInterval,
kGenScreenshotDir, kGenScreenshotDir,
kGenStateDir, kGenStateDir,
kGenStatusBar,
kGenIniVersion, kGenIniVersion,
/// Joypad /// Joypad
@ -111,7 +112,6 @@ enum class OptionID {
kGeomWindowY, kGeomWindowY,
/// UI /// UI
kUIEnableStatusBar,
kUIAllowKeyboardBackgroundInput, kUIAllowKeyboardBackgroundInput,
kUIAllowJoystickBackgroundInput, kUIAllowJoystickBackgroundInput,
kUIHideMenuBar, kUIHideMenuBar,

View File

@ -58,6 +58,7 @@ static constexpr std::array<Option::Type, kNbOptions> kOptionsTypes = {
/*kGenRewindInterval*/ Option::Type::kInt, /*kGenRewindInterval*/ Option::Type::kInt,
/*kGenScreenshotDir*/ Option::Type::kString, /*kGenScreenshotDir*/ Option::Type::kString,
/*kGenStateDir*/ Option::Type::kString, /*kGenStateDir*/ Option::Type::kString,
/*kGenStatusBar*/ Option::Type::kBool,
/*kGenIniVersion*/ Option::Type::kUnsigned, /*kGenIniVersion*/ Option::Type::kUnsigned,
/// Joypad /// Joypad
@ -115,7 +116,6 @@ static constexpr std::array<Option::Type, kNbOptions> kOptionsTypes = {
/*kGeomWindowY*/ Option::Type::kInt, /*kGeomWindowY*/ Option::Type::kInt,
/// UI /// UI
/*kUIEnableStatusBar*/ Option::Type::kBool,
/*kUIAllowKeyboardBackgroundInput*/ Option::Type::kBool, /*kUIAllowKeyboardBackgroundInput*/ Option::Type::kBool,
/*kUIAllowJoystickBackgroundInput*/ Option::Type::kBool, /*kUIAllowJoystickBackgroundInput*/ Option::Type::kBool,
/*kUIHideMenuBar*/ Option::Type::kBool, /*kUIHideMenuBar*/ Option::Type::kBool,

View File

@ -845,7 +845,7 @@ MainFrame::MainFrame()
std::bind(&MainFrame::EnableNetworkMenu, this)), std::bind(&MainFrame::EnableNetworkMenu, this)),
#endif #endif
keep_on_top_styler_(this), keep_on_top_styler_(this),
status_bar_observer_(config::OptionID::kUIEnableStatusBar, status_bar_observer_(config::OptionID::kGenStatusBar,
std::bind(&MainFrame::OnStatusBarChanged, this)) { std::bind(&MainFrame::OnStatusBarChanged, this)) {
jpoll = new JoystickPoller(); jpoll = new JoystickPoller();
this->Connect(wxID_ANY, wxEVT_SHOW, wxShowEventHandler(JoystickPoller::ShowDialog), jpoll, jpoll); this->Connect(wxID_ANY, wxEVT_SHOW, wxShowEventHandler(JoystickPoller::ShowDialog), jpoll, jpoll);
@ -860,11 +860,11 @@ MainFrame::~MainFrame() {
void MainFrame::SetStatusBar(wxStatusBar* menu_bar) { void MainFrame::SetStatusBar(wxStatusBar* menu_bar) {
wxFrame::SetStatusBar(menu_bar); wxFrame::SetStatusBar(menu_bar);
// This will take care of hiding the menu bar at startup, if needed. // This will take care of hiding the menu bar at startup, if needed.
menu_bar->Show(OPTION(kUIEnableStatusBar)); menu_bar->Show(OPTION(kGenStatusBar));
} }
void MainFrame::OnStatusBarChanged() { void MainFrame::OnStatusBarChanged() {
GetStatusBar()->Show(OPTION(kUIEnableStatusBar)); GetStatusBar()->Show(OPTION(kGenStatusBar));
SendSizeEvent(); SendSizeEvent();
panel->AdjustSize(false); panel->AdjustSize(false);
SendSizeEvent(); SendSizeEvent();

View File

@ -567,7 +567,7 @@
</object> </object>
<object class="wxMenu" name="UIConfigure"> <object class="wxMenu" name="UIConfigure">
<label>UI Settings</label> <label>UI Settings</label>
<object class="wxMenuItem" name="EnableStatusBar"> <object class="wxMenuItem" name="StatusBar">
<label>Enable _Status bar</label> <label>Enable _Status bar</label>
<checkable>1</checkable> <checkable>1</checkable>
</object> </object>