summaryrefslogtreecommitdiffstats
path: root/src/yuzu_cmd/emu_window/emu_window_sdl2.h
diff options
context:
space:
mode:
authorNeatNit <neatnit@gmail.com>2018-10-01 21:42:49 +0200
committerfearlessTobi <thm.frey@gmail.com>2018-10-09 20:26:57 +0200
commit4f24343f32ed253efb2cedba03d20c620841dca1 (patch)
tree1fffd231c45fa4681c0a20c682c3ba5f7946c27c /src/yuzu_cmd/emu_window/emu_window_sdl2.h
parentMerge pull request #1423 from DarkLordZach/romfs-file-exts (diff)
downloadyuzu-4f24343f32ed253efb2cedba03d20c620841dca1.tar
yuzu-4f24343f32ed253efb2cedba03d20c620841dca1.tar.gz
yuzu-4f24343f32ed253efb2cedba03d20c620841dca1.tar.bz2
yuzu-4f24343f32ed253efb2cedba03d20c620841dca1.tar.lz
yuzu-4f24343f32ed253efb2cedba03d20c620841dca1.tar.xz
yuzu-4f24343f32ed253efb2cedba03d20c620841dca1.tar.zst
yuzu-4f24343f32ed253efb2cedba03d20c620841dca1.zip
Diffstat (limited to '')
-rw-r--r--src/yuzu_cmd/emu_window/emu_window_sdl2.h12
1 files changed, 12 insertions, 0 deletions
diff --git a/src/yuzu_cmd/emu_window/emu_window_sdl2.h b/src/yuzu_cmd/emu_window/emu_window_sdl2.h
index d34902109..b0d4116cc 100644
--- a/src/yuzu_cmd/emu_window/emu_window_sdl2.h
+++ b/src/yuzu_cmd/emu_window/emu_window_sdl2.h
@@ -40,6 +40,18 @@ private:
/// Called by PollEvents when a mouse button is pressed or released
void OnMouseButton(u32 button, u8 state, s32 x, s32 y);
+ /// Translates pixel position (0..1) to pixel positions
+ std::pair<unsigned, unsigned> TouchToPixelPos(float touch_x, float touch_y) const;
+
+ /// Called by PollEvents when a finger starts touching the touchscreen
+ void OnFingerDown(float x, float y);
+
+ /// Called by PollEvents when a finger moves while touching the touchscreen
+ void OnFingerMotion(float x, float y);
+
+ /// Called by PollEvents when a finger stops touching the touchscreen
+ void OnFingerUp();
+
/// Called by PollEvents when any event that may cause the window to be resized occurs
void OnResize();