mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-04 08:13:54 -06:00
ui: Remove deprecated parameters of the "-display sdl" option
Dropping these deprecated parameters simplifies further refactoring (e.g. QAPIfication is easier without underscores in the name). Message-Id: <20220519155625.1414365-2-thuth@redhat.com> Reviewed-by: Daniel P. Berrangé <berrange@redhat.com> Reviewed-by: Markus Armbruster <armbru@redhat.com> Signed-off-by: Thomas Huth <thuth@redhat.com>
This commit is contained in:
parent
55c269829d
commit
a743d60bca
4 changed files with 20 additions and 86 deletions
41
softmmu/vl.c
41
softmmu/vl.c
|
@ -1079,32 +1079,7 @@ static void parse_display(const char *p)
|
|||
} else {
|
||||
goto invalid_sdl_args;
|
||||
}
|
||||
} else if (strstart(opts, ",alt_grab=", &nextopt)) {
|
||||
opts = nextopt;
|
||||
if (strstart(opts, "on", &nextopt)) {
|
||||
alt_grab = 1;
|
||||
} else if (strstart(opts, "off", &nextopt)) {
|
||||
alt_grab = 0;
|
||||
} else {
|
||||
goto invalid_sdl_args;
|
||||
}
|
||||
warn_report("alt_grab is deprecated, use grab-mod instead.");
|
||||
} else if (strstart(opts, ",ctrl_grab=", &nextopt)) {
|
||||
opts = nextopt;
|
||||
if (strstart(opts, "on", &nextopt)) {
|
||||
ctrl_grab = 1;
|
||||
} else if (strstart(opts, "off", &nextopt)) {
|
||||
ctrl_grab = 0;
|
||||
} else {
|
||||
goto invalid_sdl_args;
|
||||
}
|
||||
warn_report("ctrl_grab is deprecated, use grab-mod instead.");
|
||||
} else if (strstart(opts, ",window_close=", &nextopt) ||
|
||||
strstart(opts, ",window-close=", &nextopt)) {
|
||||
if (strstart(opts, ",window_close=", NULL)) {
|
||||
warn_report("window_close with an underscore is deprecated,"
|
||||
" please use window-close instead.");
|
||||
}
|
||||
} else if (strstart(opts, ",window-close=", &nextopt)) {
|
||||
opts = nextopt;
|
||||
dpy.has_window_close = true;
|
||||
if (strstart(opts, "on", &nextopt)) {
|
||||
|
@ -1962,10 +1937,6 @@ static void qemu_create_early_backends(void)
|
|||
const bool use_gtk = false;
|
||||
#endif
|
||||
|
||||
if ((alt_grab || ctrl_grab) && !use_sdl) {
|
||||
error_report("-alt-grab and -ctrl-grab are only valid "
|
||||
"for SDL, ignoring option");
|
||||
}
|
||||
if (dpy.has_window_close && !use_gtk && !use_sdl) {
|
||||
error_report("window-close is only valid for GTK and SDL, "
|
||||
"ignoring option");
|
||||
|
@ -3273,16 +3244,6 @@ void qemu_init(int argc, char **argv, char **envp)
|
|||
dpy.has_full_screen = true;
|
||||
dpy.full_screen = true;
|
||||
break;
|
||||
case QEMU_OPTION_alt_grab:
|
||||
alt_grab = 1;
|
||||
warn_report("-alt-grab is deprecated, please use "
|
||||
"-display sdl,grab-mod=lshift-lctrl-lalt instead.");
|
||||
break;
|
||||
case QEMU_OPTION_ctrl_grab:
|
||||
ctrl_grab = 1;
|
||||
warn_report("-ctrl-grab is deprecated, please use "
|
||||
"-display sdl,grab-mod=rctrl instead.");
|
||||
break;
|
||||
case QEMU_OPTION_sdl:
|
||||
warn_report("-sdl is deprecated, use -display sdl instead.");
|
||||
#ifdef CONFIG_SDL
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue