X-Git-Url: https://git.artsoft.org/?a=blobdiff_plain;f=src%2Flibgame%2Fsystem.h;h=a11c6b8e5da76ec4ab130936b3ea202e1b874255;hb=a1fabab3e5db1baab46a95a318b27fdf33d470cc;hp=fa422cafd8ee206c299023d8908a62430747f4ac;hpb=f7fcf0207e03bea13618e718f522c15d9120460c;p=rocksndiamonds.git diff --git a/src/libgame/system.h b/src/libgame/system.h index fa422caf..a11c6b8e 100644 --- a/src/libgame/system.h +++ b/src/libgame/system.h @@ -85,6 +85,7 @@ /* values for touch control */ #define TOUCH_CONTROL_VIRTUAL_BUTTONS "virtual_buttons" #define TOUCH_CONTROL_WIPE_GESTURES "wipe_gestures" +#define TOUCH_CONTROL_FOLLOW_FINGER "follow_finger" #define TOUCH_CONTROL_DEFAULT TOUCH_CONTROL_VIRTUAL_BUTTONS @@ -92,6 +93,13 @@ #define TOUCH_DROP_DISTANCE_DEFAULT 5 +/* values for screen keyboard on mobile devices */ +#if defined(PLATFORM_ANDROID) +#define HAS_SCREEN_KEYBOARD +#define SCREEN_KEYBOARD_POS(h) ((h) / 2) +#endif + + /* default input keys */ #define DEFAULT_KEY_LEFT KSYM_Left #define DEFAULT_KEY_RIGHT KSYM_Right @@ -715,14 +723,6 @@ } -/* type definitions */ -#if defined(TARGET_SDL2) -typedef int (*EventFilter)(void *, Event *); -#else -typedef int (*EventFilter)(const Event *); -#endif - - /* structure definitions */ struct ProgramInfo @@ -801,6 +801,12 @@ struct VideoSystemInfo unsigned int frame_delay; unsigned int frame_delay_value; + boolean shifted_up; + int shifted_up_pos; + int shifted_up_pos_last; + unsigned int shifted_up_delay; + unsigned int shifted_up_delay_value; + boolean initialized; }; @@ -1294,6 +1300,12 @@ struct XY int x, y; }; +struct XYTileSize +{ + int x, y; + int tile_size; +}; + struct Rect { int x, y; @@ -1474,7 +1486,6 @@ void OpenAudio(void); void CloseAudio(void); void SetAudioMode(boolean); -void InitEventFilter(EventFilter); boolean PendingEvent(void); void NextEvent(Event *event); void PeekEvent(Event *event); @@ -1482,6 +1493,8 @@ Key GetEventKey(KeyEvent *, boolean); KeyMod HandleKeyModState(Key, int); KeyMod GetKeyModState(); KeyMod GetKeyModStateFromEvents(); +void StartTextInput(int, int, int, int); +void StopTextInput(); boolean CheckCloseWindowEvent(ClientMessageEvent *); void InitJoysticks();