From 459488a2e777380fcb65e3b4dd355fe525ff77ca Mon Sep 17 00:00:00 2001 From: Akshay Nair Date: Tue, 24 Dec 2024 22:28:38 +0530 Subject: Add search mode for text based searching with ocr --- src/Chelleport/Control.hs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/Chelleport/Control.hs') diff --git a/src/Chelleport/Control.hs b/src/Chelleport/Control.hs index 80be6f8..f7a9c66 100644 --- a/src/Chelleport/Control.hs +++ b/src/Chelleport/Control.hs @@ -64,10 +64,10 @@ instance (MonadIO m) => MonadControl (AppM m) where X11.sync display False isKeyPressed :: SDL.KeyboardEventData -> Bool -isKeyPressed = (== SDL.Pressed) . SDL.keyboardEventKeyMotion +isKeyPressed = (SDL.Pressed ==) . SDL.keyboardEventKeyMotion isKeyRelease :: SDL.KeyboardEventData -> Bool -isKeyRelease = (== SDL.Released) . SDL.keyboardEventKeyMotion +isKeyRelease = (SDL.Released ==) . SDL.keyboardEventKeyMotion eventToKeycode :: SDL.KeyboardEventData -> SDL.Keycode eventToKeycode = SDL.keysymKeycode . SDL.keyboardEventKeysym -- cgit v1.3.1