From b3c69f4cbfc11b15c2725f5c71465860694d5933 Mon Sep 17 00:00:00 2001 From: dec05eba Date: Fri, 27 Aug 2021 18:34:09 +0200 Subject: Fix quickmedia closing on ctrl+f when viewing a video instead of going into fullscreen mode --- src/QuickMedia.cpp | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/QuickMedia.cpp b/src/QuickMedia.cpp index f11b69f..5d47f89 100644 --- a/src/QuickMedia.cpp +++ b/src/QuickMedia.cpp @@ -3088,10 +3088,9 @@ namespace QuickMedia { KeySym pressed_keysym = XKeycodeToKeysym(disp, xev.xkey.keycode, 0); #pragma GCC diagnostic pop bool pressing_ctrl = (CLEANMASK(xev.xkey.state) == ControlMask); - if(pressed_keysym && pressing_ctrl) { + if(pressed_keysym == XK_q && pressing_ctrl) { window.close(); - } - if(pressed_keysym == XK_Escape || pressed_keysym == XK_q || pressed_keysym == XK_BackSpace) { + } else if(pressed_keysym == XK_Escape || pressed_keysym == XK_q || pressed_keysym == XK_BackSpace) { if(window_is_fullscreen(disp, window.getSystemHandle())) { window_set_fullscreen(disp, window.getSystemHandle(), WindowFullscreenState::UNSET); } else { -- cgit v1.2.3