mirror of
https://github.com/hrydgard/ppsspp.git
synced 2026-11-15 10:40:01 +01:00
Windows app (not headless): Inform the user of bad command line parameters, but proceed.
This commit is contained in:
1 parent
3ca6ab6a79
commit
b5f91caae4
1 file changed
+11
@@ -557,6 +557,17 @@ CommandLineParseResult CommandLineOptions::Parse(int argc, const char *argv[], C
|
||||
}
|
||||
} else if (startsWith(argv[i], "--")) {
|
||||
PRINT_STDERR("Error: Unknown parameter: %s\n", argv[i]);
|
||||
if (mode == CmdLineMode::Application) {
|
||||
// Ignore bad parameters - but inform the user in the Windows debug output at least.
|
||||
OutputDebugStringUTF8("Warning: Unknown parameter: ");
|
||||
OutputDebugStringUTF8(argv[i]);
|
||||
OutputDebugStringUTF8("\n");
|
||||
|
||||
std::string msg = StringFromFormat("Unknown command line parameter: %s\n\nProceeding anyway.", argv[i]);
|
||||
ShowMessageDialog("Unknown Parameter", msg.c_str(), true);
|
||||
|
||||
return CommandLineParseResult::Continue;
|
||||
}
|
||||
return CommandLineParseResult::Error;
|
||||
}
|
||||
// To the next argument.
|
||||
|
||||
Reference in new issue
Block a user