mirror of
https://github.com/FWGS/xash3d-fwgs.git
synced 2026-08-05 03:24:56 +08:00
engine: client: add ability to build engine without touch input support
This commit is contained in:
@@ -51,6 +51,8 @@ void IN_SetMouseGrab( qboolean set );
|
||||
|
||||
extern convar_t m_yaw;
|
||||
extern convar_t m_pitch;
|
||||
extern convar_t touch_enable;
|
||||
|
||||
//
|
||||
// in_touch.c
|
||||
//
|
||||
@@ -61,8 +63,23 @@ typedef enum
|
||||
event_motion
|
||||
} touchEventType;
|
||||
|
||||
extern convar_t touch_enable;
|
||||
|
||||
#if XASH_NO_TOUCH
|
||||
static inline void Touch_Draw( void ) { }
|
||||
static inline void Touch_SetClientOnly( byte state ) { }
|
||||
static inline void Touch_RemoveButton( const char *name, qboolean privileged ) { }
|
||||
static inline void Touch_HideButtons( const char *name, unsigned char hide, qboolean privileged ) { }
|
||||
static inline void Touch_AddClientButton( const char *name, const char *texture, const char *command, float x1, float y1, float x2, float y2, byte *color, int round, float aspect, int flags ) { }
|
||||
static inline void Touch_AddDefaultButton( const char *name, const char *texturefile, const char *command, float x1, float y1, float x2, float y2, byte *color, int round, float aspect, int flags ) { }
|
||||
static inline void Touch_WriteConfig( void ) { }
|
||||
static inline void Touch_Init( void ) { }
|
||||
static inline void Touch_Shutdown( void ) { }
|
||||
static inline void Touch_GetMove( float * forward, float *side, float *yaw, float *pitch ) { }
|
||||
static inline void Touch_ResetDefaultButtons( void ) { }
|
||||
static inline int IN_TouchEvent( touchEventType type, int fingerID, float x, float y, float dx, float dy ) { return 0; }
|
||||
static inline void Touch_KeyEvent( int key, int down ) { }
|
||||
static inline qboolean Touch_WantVisibleCursor( void ) { return false; }
|
||||
static inline void Touch_NotifyResize( void ) { }
|
||||
#else
|
||||
void Touch_Draw( void );
|
||||
void Touch_SetClientOnly( byte state );
|
||||
void Touch_RemoveButton( const char *name, qboolean privileged );
|
||||
@@ -78,6 +95,7 @@ int IN_TouchEvent( touchEventType type, int fingerID, float x, float y, float dx
|
||||
void Touch_KeyEvent( int key, int down );
|
||||
qboolean Touch_WantVisibleCursor( void );
|
||||
void Touch_NotifyResize( void );
|
||||
#endif
|
||||
|
||||
//
|
||||
// in_joy.c
|
||||
|
||||
Reference in New Issue
Block a user