[client] always use spice mouse host mode

Since we only ever use offset movements as SPICE doesn't properly
support absolute x/y positional information without a virtual tablet
device (which breaks relative mode needed for capture), just always run
in this mode. This fixes an issue when the spice guest tools are
installed and the mouse fails to work when not captured.
This commit is contained in:
Geoffrey McRae 2020-08-09 16:17:08 +10:00
parent 1899d9f1da
commit 3302d353cf
2 changed files with 2 additions and 3 deletions

View file

@ -1 +1 @@
B2-rc2-30-gfb9b772db0+1
B2-rc2-31-g1899d9f1da+1

View file

@ -929,7 +929,6 @@ int eventFilter(void * userdata, SDL_Event * event)
if (params.useSpiceInput)
{
state.serverMode = !state.serverMode;
spice_mouse_mode(state.serverMode);
SDL_SetWindowGrab(state.window, state.serverMode);
DEBUG_INFO("Server Mode: %s", state.serverMode ? "on" : "off");
@ -1236,6 +1235,7 @@ static int lg_run()
return -1;
}
spice_mouse_mode(true);
if (!lgCreateThread("spiceThread", spiceThread, NULL, &t_spice))
{
DEBUG_ERROR("spice create thread failed");
@ -1407,7 +1407,6 @@ static int lg_run()
if (params.captureOnStart)
{
state.serverMode = true;
spice_mouse_mode(state.serverMode);
SDL_SetWindowGrab(state.window, state.serverMode);
DEBUG_INFO("Server Mode: %s", state.serverMode ? "on" : "off");
}