qt: fix mouse cursor limited by window range on F5 press

This commit is contained in:
Tatsuya79 2021-02-04 17:54:05 +01:00 committed by GitHub
parent bfe5ca708b
commit 502d3b3514
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -660,16 +660,15 @@ static void ui_companion_qt_toggle(void *data, bool force)
if (ui_companion_toggle || force)
{
if (mouse_grabbed)
command_event(CMD_EVENT_GRAB_MOUSE_TOGGLE, NULL);
video_driver_show_mouse();
if (video_fullscreen)
command_event(CMD_EVENT_FULLSCREEN_TOGGLE, NULL);
win_handle->qtWindow->activateWindow();
win_handle->qtWindow->raise();
if (mouse_grabbed)
command_event(CMD_EVENT_GRAB_MOUSE_TOGGLE, NULL);
video_driver_show_mouse();
win_handle->qtWindow->show();
if (video_driver_started_fullscreen())