mirror of https://github.com/bsnes-emu/bsnes.git
Add dismissable warning when using nightlies.
This commit is contained in:
parent
66ad62b79f
commit
46dbe00f14
|
@ -42,6 +42,7 @@ auto nall::main(Arguments arguments) -> void {
|
|||
Application::setName("bsnes");
|
||||
Application::setScreenSaver(settings.general.screenSaver);
|
||||
Application::setToolTips(settings.general.toolTips);
|
||||
|
||||
Instances::presentation.construct();
|
||||
Instances::settingsWindow.construct();
|
||||
Instances::cheatDatabase.construct();
|
||||
|
@ -50,6 +51,23 @@ auto nall::main(Arguments arguments) -> void {
|
|||
Instances::toolsWindow.construct();
|
||||
emulator = new SuperFamicom::Interface;
|
||||
program.create();
|
||||
|
||||
if(Emulator::Version.find(".") && settings.general.betaWarning) {
|
||||
MessageDialog dialog;
|
||||
dialog.setTitle(Emulator::Name);
|
||||
dialog.setText(
|
||||
"This is a nightly release. Bugs and regressions are possible!\n"
|
||||
"If you experience issues, please report them to me.\n"
|
||||
"If stability is required, please use a stable release.\n"
|
||||
);
|
||||
dialog.setOption("Don't show this message again");
|
||||
dialog.information();
|
||||
if(dialog.checked()) {
|
||||
settings.general.betaWarning = false;
|
||||
settings.save();
|
||||
}
|
||||
}
|
||||
|
||||
Application::run();
|
||||
Instances::presentation.destruct();
|
||||
Instances::settingsWindow.destruct();
|
||||
|
|
|
@ -128,6 +128,7 @@ auto Settings::process(bool load) -> void {
|
|||
bind(boolean, "General/ScreenSaver", general.screenSaver);
|
||||
bind(boolean, "General/ToolTips", general.toolTips);
|
||||
bind(boolean, "General/Crashed", general.crashed);
|
||||
bind(boolean, "General/BetaWarning", general.betaWarning);
|
||||
|
||||
#undef bind
|
||||
}
|
||||
|
|
|
@ -130,6 +130,7 @@ struct Settings : Markup::Node {
|
|||
bool screenSaver = false;
|
||||
bool toolTips = true;
|
||||
bool crashed = false;
|
||||
bool betaWarning = true;
|
||||
} general;
|
||||
};
|
||||
|
||||
|
|
Loading…
Reference in New Issue