-
-
Notifications
You must be signed in to change notification settings - Fork 31
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
6 changed files
with
56 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
#include "stream/input/session_input.h" | ||
|
||
void stream_input_handle_touch(const stream_input_t *input, const SDL_TouchFingerEvent *event) { | ||
if (input->view_only) { | ||
return; | ||
} | ||
uint8_t type; | ||
switch (event->type) { | ||
case SDL_FINGERDOWN: | ||
type = LI_TOUCH_EVENT_DOWN; | ||
break; | ||
case SDL_FINGERUP: | ||
type = LI_TOUCH_EVENT_UP; | ||
break; | ||
case SDL_FINGERMOTION: | ||
type = LI_TOUCH_EVENT_MOVE; | ||
break; | ||
default: | ||
return; | ||
} | ||
LiSendTouchEvent(type, event->fingerId, event->x, event->y, event->pressure, 0, 0, 0); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters