mirror of
https://github.com/lc-soft/LCUI.git
synced 2026-11-30 16:48:21 +01:00
Add ENABLE_TOUCH_SUPPORT macro
This commit is contained in:
@@ -75,6 +75,7 @@
|
||||
#define USE_LIBPNG
|
||||
#define USE_LIBJPEG
|
||||
#define USE_LCUI_BUILDER
|
||||
#define ENABLE_TOUCH_SUPPORT
|
||||
#undef LCUI_THREAD_PTHREAD
|
||||
#undef LCUI_VIDEO_DRIVER_FRAMEBUFFER
|
||||
#else
|
||||
|
||||
@@ -162,7 +162,9 @@ static void OnCreateSurface( void *arg1, void *arg2 )
|
||||
0, 0, NULL, NULL,
|
||||
instance, NULL
|
||||
);
|
||||
#ifdef ENABLE_TOUCH_SUPPORT
|
||||
RegisterTouchWindow( surface->hwnd, 0 );
|
||||
#endif
|
||||
surface->hdc_client = GetDC( surface->hwnd );
|
||||
surface->hdc_fb = CreateCompatibleDC( surface->hdc_client );
|
||||
surface->is_ready = TRUE;
|
||||
|
||||
@@ -99,6 +99,7 @@ static void OnMouseMessage( LCUI_Event ev, void *arg )
|
||||
sys_ev.wheel.y = mouse_pos.y;
|
||||
sys_ev.wheel.delta = GET_WHEEL_DELTA_WPARAM( msg->wParam );
|
||||
break;
|
||||
#ifdef ENABLE_TOUCH_SUPPORT
|
||||
case WM_TOUCH: {
|
||||
UINT i, n = LOWORD( msg->wParam );
|
||||
PTOUCHINPUT inputs = NEW( TOUCHINPUT, n );
|
||||
@@ -145,6 +146,7 @@ static void OnMouseMessage( LCUI_Event ev, void *arg )
|
||||
}
|
||||
break;
|
||||
}
|
||||
#endif
|
||||
default: break;
|
||||
}
|
||||
if( sys_ev.type != LCUI_NONE ) {
|
||||
|
||||
Reference in New Issue
Block a user