mirror of
https://github.com/gnif/LookingGlass.git
synced 2025-04-26 00:26:32 +00:00
[client] spice: show message when connected to the wrong guest
This commit is contained in:
parent
780cf5f362
commit
d42e409728
@ -805,8 +805,14 @@ static void checkUUID(void)
|
|||||||
sizeof(g_state.spiceUUID)) == 0)
|
sizeof(g_state.spiceUUID)) == 0)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
DEBUG_ERROR("UUIDs do not match, you have connected SPICE to the wrong guest");
|
app_msgBox(
|
||||||
g_state.state = APP_STATE_SHUTDOWN;
|
"SPICE Configuration Error",
|
||||||
|
"You have connected SPICE to the wrong guest.\n"
|
||||||
|
"Input will not function until this is corrected.");
|
||||||
|
|
||||||
|
g_params.useSpiceInput = false;
|
||||||
|
g_state.spiceClose = true;
|
||||||
|
purespice_disconnect();
|
||||||
}
|
}
|
||||||
|
|
||||||
void spiceReady(void)
|
void spiceReady(void)
|
||||||
@ -899,7 +905,12 @@ int spiceThread(void * arg)
|
|||||||
end:
|
end:
|
||||||
|
|
||||||
audio_free();
|
audio_free();
|
||||||
g_state.state = APP_STATE_SHUTDOWN;
|
|
||||||
|
// if the connection was disconnected intentionally we don't want to shutdown
|
||||||
|
// so that the user can see the message box and take action
|
||||||
|
if (!g_state.spiceClose)
|
||||||
|
g_state.state = APP_STATE_SHUTDOWN;
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -94,6 +94,7 @@ struct AppState
|
|||||||
LG_RendererRect dstRect;
|
LG_RendererRect dstRect;
|
||||||
bool posInfoValid;
|
bool posInfoValid;
|
||||||
bool alignToGuest;
|
bool alignToGuest;
|
||||||
|
bool spiceClose;
|
||||||
|
|
||||||
LG_Renderer * lgr;
|
LG_Renderer * lgr;
|
||||||
atomic_int lgrResize;
|
atomic_int lgrResize;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user