Adapted to new input event handling.
This commit is contained in:
parent
2b067584e9
commit
a11ce32ad4
@ -45,7 +45,7 @@
|
|||||||
#include "debug.h"
|
#include "debug.h"
|
||||||
#include "task.h"
|
#include "task.h"
|
||||||
#include "user.h"
|
#include "user.h"
|
||||||
#include "keyboard.h"
|
#include "input.h"
|
||||||
#include "x11drv.h"
|
#include "x11drv.h"
|
||||||
#include "winerror.h"
|
#include "winerror.h"
|
||||||
|
|
||||||
|
378
windows/event.c
378
windows/event.c
@ -36,10 +36,11 @@
|
|||||||
#include "drive.h"
|
#include "drive.h"
|
||||||
#include "shell.h"
|
#include "shell.h"
|
||||||
#include "keyboard.h"
|
#include "keyboard.h"
|
||||||
|
#include "mouse.h"
|
||||||
#include "debug.h"
|
#include "debug.h"
|
||||||
#include "dde_proc.h"
|
#include "dde_proc.h"
|
||||||
#include "winsock.h"
|
#include "winsock.h"
|
||||||
#include "callback.h"
|
#include "mouse.h"
|
||||||
|
|
||||||
|
|
||||||
#define NB_BUTTONS 3 /* Windows can handle 3 buttons */
|
#define NB_BUTTONS 3 /* Windows can handle 3 buttons */
|
||||||
@ -62,11 +63,6 @@
|
|||||||
/* X context to associate a hwnd to an X window */
|
/* X context to associate a hwnd to an X window */
|
||||||
static XContext winContext = 0;
|
static XContext winContext = 0;
|
||||||
|
|
||||||
static INT16 captureHT = HTCLIENT;
|
|
||||||
static HWND32 captureWnd = 0;
|
|
||||||
static BOOL32 InputEnabled = TRUE;
|
|
||||||
static BOOL32 SwappedButtons = FALSE;
|
|
||||||
|
|
||||||
static Atom wmProtocols = None;
|
static Atom wmProtocols = None;
|
||||||
static Atom wmDeleteWindow = None;
|
static Atom wmDeleteWindow = None;
|
||||||
static Atom dndProtocol = None;
|
static Atom dndProtocol = None;
|
||||||
@ -112,8 +108,6 @@ static void EVENT_EnterNotify( WND *pWnd, XCrossingEvent *event );
|
|||||||
|
|
||||||
static void EVENT_GetGeometry( Window win, int *px, int *py,
|
static void EVENT_GetGeometry( Window win, int *px, int *py,
|
||||||
unsigned int *pwidth, unsigned int *pheight );
|
unsigned int *pwidth, unsigned int *pheight );
|
||||||
static void EVENT_SendMouseEvent( WORD mouseStatus, WORD deltaX, WORD deltaY,
|
|
||||||
WORD buttonCount, DWORD extraInfo );
|
|
||||||
|
|
||||||
/***********************************************************************
|
/***********************************************************************
|
||||||
* EVENT_Init
|
* EVENT_Init
|
||||||
@ -178,18 +172,15 @@ void EVENT_ProcessEvent( XEvent *event )
|
|||||||
{
|
{
|
||||||
case KeyPress:
|
case KeyPress:
|
||||||
case KeyRelease:
|
case KeyRelease:
|
||||||
if (!pWnd) return;
|
EVENT_Key( pWnd, (XKeyEvent*)event );
|
||||||
if (InputEnabled) EVENT_Key( pWnd, (XKeyEvent*)event );
|
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case ButtonPress:
|
case ButtonPress:
|
||||||
if (InputEnabled)
|
EVENT_ButtonPress( pWnd, (XButtonEvent*)event );
|
||||||
EVENT_ButtonPress( pWnd, (XButtonEvent*)event );
|
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case ButtonRelease:
|
case ButtonRelease:
|
||||||
if (InputEnabled)
|
EVENT_ButtonRelease( pWnd, (XButtonEvent*)event );
|
||||||
EVENT_ButtonRelease( pWnd, (XButtonEvent*)event );
|
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case MotionNotify:
|
case MotionNotify:
|
||||||
@ -201,12 +192,9 @@ void EVENT_ProcessEvent( XEvent *event )
|
|||||||
problems if the event order is important. I'm not yet seen
|
problems if the event order is important. I'm not yet seen
|
||||||
of any problems. Jon 7/6/96.
|
of any problems. Jon 7/6/96.
|
||||||
*/
|
*/
|
||||||
if (InputEnabled)
|
while (TSXCheckTypedWindowEvent(display,((XAnyEvent *)event)->window,
|
||||||
{
|
MotionNotify, event));
|
||||||
while (TSXCheckTypedWindowEvent(display,((XAnyEvent *)event)->window,
|
EVENT_MotionNotify( pWnd, (XMotionEvent*)event );
|
||||||
MotionNotify, event));
|
|
||||||
EVENT_MotionNotify( pWnd, (XMotionEvent*)event );
|
|
||||||
}
|
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case FocusIn:
|
case FocusIn:
|
||||||
@ -650,6 +638,25 @@ static WORD EVENT_XStateToKeyState( int state )
|
|||||||
return kstate;
|
return kstate;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/***********************************************************************
|
||||||
|
* EVENT_QueryPointer
|
||||||
|
*/
|
||||||
|
BOOL32 EVENT_QueryPointer( DWORD *posX, DWORD *posY, DWORD *state )
|
||||||
|
{
|
||||||
|
Window root, child;
|
||||||
|
int rootX, rootY, winX, winY;
|
||||||
|
unsigned int xstate;
|
||||||
|
|
||||||
|
if (!TSXQueryPointer( display, rootWindow, &root, &child,
|
||||||
|
&rootX, &rootY, &winX, &winY, &xstate ))
|
||||||
|
return FALSE;
|
||||||
|
|
||||||
|
*posX = (DWORD)winX;
|
||||||
|
*posY = (DWORD)winY;
|
||||||
|
*state = EVENT_XStateToKeyState( xstate );
|
||||||
|
|
||||||
|
return TRUE;
|
||||||
|
}
|
||||||
|
|
||||||
/***********************************************************************
|
/***********************************************************************
|
||||||
* EVENT_Expose
|
* EVENT_Expose
|
||||||
@ -726,16 +733,11 @@ static void EVENT_MotionNotify( WND *pWnd, XMotionEvent *event )
|
|||||||
int xOffset = pWnd? pWnd->rectWindow.left : 0;
|
int xOffset = pWnd? pWnd->rectWindow.left : 0;
|
||||||
int yOffset = pWnd? pWnd->rectWindow.top : 0;
|
int yOffset = pWnd? pWnd->rectWindow.top : 0;
|
||||||
|
|
||||||
if (pWnd)
|
MOUSE_SendEvent( MOUSEEVENTF_MOVE,
|
||||||
hardware_event( WM_MOUSEMOVE, EVENT_XStateToKeyState( event->state ), 0L,
|
xOffset + event->x, yOffset + event->y,
|
||||||
xOffset + event->x,
|
EVENT_XStateToKeyState( event->state ),
|
||||||
yOffset + event->y,
|
event->time - MSG_WineStartTicks,
|
||||||
event->time - MSG_WineStartTicks, pWnd->hwndSelf );
|
pWnd? pWnd->hwndSelf : 0 );
|
||||||
|
|
||||||
EVENT_SendMouseEvent( ME_MOVE,
|
|
||||||
xOffset + event->x,
|
|
||||||
yOffset + event->y,
|
|
||||||
0, 0 );
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -746,15 +748,12 @@ static void EVENT_MotionNotify( WND *pWnd, XMotionEvent *event )
|
|||||||
*/
|
*/
|
||||||
void EVENT_DummyMotionNotify(void)
|
void EVENT_DummyMotionNotify(void)
|
||||||
{
|
{
|
||||||
Window root, child;
|
DWORD winX, winY, state;
|
||||||
int rootX, rootY, winX, winY;
|
|
||||||
unsigned int state;
|
|
||||||
|
|
||||||
if (TSXQueryPointer( display, rootWindow, &root, &child,
|
if ( EVENT_QueryPointer( &winX, &winY, &state ) )
|
||||||
&rootX, &rootY, &winX, &winY, &state ))
|
|
||||||
{
|
{
|
||||||
hardware_event( WM_MOUSEMOVE, EVENT_XStateToKeyState( state ), 0L,
|
MOUSE_SendEvent( MOUSEEVENTF_MOVE, winX, winY, state,
|
||||||
winX, winY, GetTickCount(), 0 );
|
GetTickCount(), 0 );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -764,31 +763,20 @@ void EVENT_DummyMotionNotify(void)
|
|||||||
*/
|
*/
|
||||||
static void EVENT_ButtonPress( WND *pWnd, XButtonEvent *event )
|
static void EVENT_ButtonPress( WND *pWnd, XButtonEvent *event )
|
||||||
{
|
{
|
||||||
static WORD messages[NB_BUTTONS] =
|
|
||||||
{ WM_LBUTTONDOWN, WM_MBUTTONDOWN, WM_RBUTTONDOWN };
|
|
||||||
static WORD statusCodes[NB_BUTTONS] =
|
static WORD statusCodes[NB_BUTTONS] =
|
||||||
{ ME_LDOWN, 0, ME_RDOWN };
|
{ MOUSEEVENTF_LEFTDOWN, MOUSEEVENTF_MIDDLEDOWN, MOUSEEVENTF_RIGHTDOWN };
|
||||||
int buttonNum = event->button - 1;
|
int buttonNum = event->button - 1;
|
||||||
|
|
||||||
int xOffset = pWnd? pWnd->rectWindow.left : 0;
|
int xOffset = pWnd? pWnd->rectWindow.left : 0;
|
||||||
int yOffset = pWnd? pWnd->rectWindow.top : 0;
|
int yOffset = pWnd? pWnd->rectWindow.top : 0;
|
||||||
|
|
||||||
if (buttonNum >= NB_BUTTONS) return;
|
if (buttonNum >= NB_BUTTONS) return;
|
||||||
if (SwappedButtons) buttonNum = NB_BUTTONS - 1 - buttonNum;
|
|
||||||
MouseButtonsStates[buttonNum] = TRUE;
|
|
||||||
AsyncMouseButtonsStates[buttonNum] = TRUE;
|
|
||||||
|
|
||||||
if (pWnd)
|
MOUSE_SendEvent( statusCodes[buttonNum],
|
||||||
hardware_event( messages[buttonNum],
|
xOffset + event->x, yOffset + event->y,
|
||||||
EVENT_XStateToKeyState( event->state ), 0L,
|
EVENT_XStateToKeyState( event->state ),
|
||||||
xOffset + event->x,
|
event->time - MSG_WineStartTicks,
|
||||||
yOffset + event->y,
|
pWnd? pWnd->hwndSelf : 0 );
|
||||||
event->time - MSG_WineStartTicks, pWnd->hwndSelf );
|
|
||||||
|
|
||||||
EVENT_SendMouseEvent( statusCodes[buttonNum],
|
|
||||||
xOffset + event->x,
|
|
||||||
yOffset + event->y,
|
|
||||||
0, 0 );
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -797,30 +785,20 @@ static void EVENT_ButtonPress( WND *pWnd, XButtonEvent *event )
|
|||||||
*/
|
*/
|
||||||
static void EVENT_ButtonRelease( WND *pWnd, XButtonEvent *event )
|
static void EVENT_ButtonRelease( WND *pWnd, XButtonEvent *event )
|
||||||
{
|
{
|
||||||
static const WORD messages[NB_BUTTONS] =
|
|
||||||
{ WM_LBUTTONUP, WM_MBUTTONUP, WM_RBUTTONUP };
|
|
||||||
static WORD statusCodes[NB_BUTTONS] =
|
static WORD statusCodes[NB_BUTTONS] =
|
||||||
{ ME_LUP, 0, ME_RUP };
|
{ MOUSEEVENTF_LEFTUP, MOUSEEVENTF_MIDDLEUP, MOUSEEVENTF_RIGHTUP };
|
||||||
int buttonNum = event->button - 1;
|
int buttonNum = event->button - 1;
|
||||||
|
|
||||||
int xOffset = pWnd? pWnd->rectWindow.left : 0;
|
int xOffset = pWnd? pWnd->rectWindow.left : 0;
|
||||||
int yOffset = pWnd? pWnd->rectWindow.top : 0;
|
int yOffset = pWnd? pWnd->rectWindow.top : 0;
|
||||||
|
|
||||||
if (buttonNum >= NB_BUTTONS) return;
|
if (buttonNum >= NB_BUTTONS) return;
|
||||||
if (SwappedButtons) buttonNum = NB_BUTTONS - 1 - buttonNum;
|
|
||||||
MouseButtonsStates[buttonNum] = FALSE;
|
|
||||||
|
|
||||||
if (pWnd)
|
MOUSE_SendEvent( statusCodes[buttonNum],
|
||||||
hardware_event( messages[buttonNum],
|
xOffset + event->x, yOffset + event->y,
|
||||||
EVENT_XStateToKeyState( event->state ), 0L,
|
EVENT_XStateToKeyState( event->state ),
|
||||||
xOffset + event->x,
|
event->time - MSG_WineStartTicks,
|
||||||
yOffset + event->y,
|
pWnd? pWnd->hwndSelf : 0 );
|
||||||
event->time - MSG_WineStartTicks, pWnd->hwndSelf );
|
|
||||||
|
|
||||||
EVENT_SendMouseEvent( statusCodes[buttonNum],
|
|
||||||
xOffset + event->x,
|
|
||||||
yOffset + event->y,
|
|
||||||
0, 0 );
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -1412,263 +1390,3 @@ void EVENT_MapNotify( HWND32 hWnd, XMapEvent *event )
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**********************************************************************
|
|
||||||
* EVENT_Capture
|
|
||||||
*
|
|
||||||
* We need this to be able to generate double click messages
|
|
||||||
* when menu code captures mouse in the window without CS_DBLCLK style.
|
|
||||||
*/
|
|
||||||
HWND32 EVENT_Capture(HWND32 hwnd, INT16 ht)
|
|
||||||
{
|
|
||||||
HWND32 capturePrev = captureWnd;
|
|
||||||
|
|
||||||
if (!hwnd)
|
|
||||||
{
|
|
||||||
captureWnd = 0L;
|
|
||||||
captureHT = 0;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
WND* wndPtr = WIN_FindWndPtr( hwnd );
|
|
||||||
if (wndPtr)
|
|
||||||
{
|
|
||||||
TRACE(win, "(0x%04x)\n", hwnd );
|
|
||||||
captureWnd = hwnd;
|
|
||||||
captureHT = ht;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
if( capturePrev && capturePrev != captureWnd )
|
|
||||||
{
|
|
||||||
WND* wndPtr = WIN_FindWndPtr( capturePrev );
|
|
||||||
if( wndPtr && (wndPtr->flags & WIN_ISWIN32) )
|
|
||||||
SendMessage32A( capturePrev, WM_CAPTURECHANGED, 0L, hwnd);
|
|
||||||
}
|
|
||||||
return capturePrev;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**********************************************************************
|
|
||||||
* EVENT_GetCaptureInfo
|
|
||||||
*/
|
|
||||||
INT16 EVENT_GetCaptureInfo()
|
|
||||||
{
|
|
||||||
return captureHT;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**********************************************************************
|
|
||||||
* SetCapture16 (USER.18)
|
|
||||||
*/
|
|
||||||
HWND16 WINAPI SetCapture16( HWND16 hwnd )
|
|
||||||
{
|
|
||||||
return (HWND16)EVENT_Capture( hwnd, HTCLIENT );
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
/**********************************************************************
|
|
||||||
* SetCapture32 (USER32.464)
|
|
||||||
*/
|
|
||||||
HWND32 WINAPI SetCapture32( HWND32 hwnd )
|
|
||||||
{
|
|
||||||
return EVENT_Capture( hwnd, HTCLIENT );
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
/**********************************************************************
|
|
||||||
* ReleaseCapture (USER.19) (USER32.439)
|
|
||||||
*/
|
|
||||||
void WINAPI ReleaseCapture(void)
|
|
||||||
{
|
|
||||||
TRACE(win, "captureWnd=%04x\n", captureWnd );
|
|
||||||
if( captureWnd ) EVENT_Capture( 0, 0 );
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
/**********************************************************************
|
|
||||||
* GetCapture16 (USER.236)
|
|
||||||
*/
|
|
||||||
HWND16 WINAPI GetCapture16(void)
|
|
||||||
{
|
|
||||||
return captureWnd;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
/**********************************************************************
|
|
||||||
* GetCapture32 (USER32.208)
|
|
||||||
*/
|
|
||||||
HWND32 WINAPI GetCapture32(void)
|
|
||||||
{
|
|
||||||
return captureWnd;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/***********************************************************************
|
|
||||||
* Mouse driver routines:
|
|
||||||
*/
|
|
||||||
|
|
||||||
#pragma pack(1)
|
|
||||||
typedef struct _MOUSEINFO
|
|
||||||
{
|
|
||||||
BYTE msExist;
|
|
||||||
BYTE msRelative;
|
|
||||||
WORD msNumButtons;
|
|
||||||
WORD msRate;
|
|
||||||
WORD msXThreshold;
|
|
||||||
WORD msYThreshold;
|
|
||||||
WORD msXRes;
|
|
||||||
WORD msYRes;
|
|
||||||
WORD msMouseCommPort;
|
|
||||||
} MOUSEINFO;
|
|
||||||
#pragma pack(4)
|
|
||||||
|
|
||||||
static SEGPTR MouseEventProc = 0;
|
|
||||||
|
|
||||||
/***********************************************************************
|
|
||||||
* MouseInquire (MOUSE.1)
|
|
||||||
*/
|
|
||||||
|
|
||||||
WORD WINAPI MouseInquire(MOUSEINFO *mouseInfo)
|
|
||||||
{
|
|
||||||
mouseInfo->msExist = TRUE;
|
|
||||||
mouseInfo->msRelative = FALSE;
|
|
||||||
mouseInfo->msNumButtons = 2;
|
|
||||||
mouseInfo->msRate = 34; /* the DDK says so ... */
|
|
||||||
mouseInfo->msXThreshold = 0;
|
|
||||||
mouseInfo->msYThreshold = 0;
|
|
||||||
mouseInfo->msXRes = 0;
|
|
||||||
mouseInfo->msYRes = 0;
|
|
||||||
mouseInfo->msMouseCommPort = 0;
|
|
||||||
|
|
||||||
return sizeof(MOUSEINFO);
|
|
||||||
}
|
|
||||||
|
|
||||||
/***********************************************************************
|
|
||||||
* MouseEnable (MOUSE.2)
|
|
||||||
*/
|
|
||||||
VOID WINAPI MouseEnable(SEGPTR eventProc)
|
|
||||||
{
|
|
||||||
MouseEventProc = eventProc;
|
|
||||||
}
|
|
||||||
|
|
||||||
/***********************************************************************
|
|
||||||
* MouseDisable (MOUSE.3)
|
|
||||||
*/
|
|
||||||
VOID WINAPI MouseDisable(VOID)
|
|
||||||
{
|
|
||||||
MouseEventProc = 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
/***********************************************************************
|
|
||||||
* EVENT_SendMouseEvent
|
|
||||||
*/
|
|
||||||
static void EVENT_SendMouseEvent( WORD mouseStatus, WORD deltaX, WORD deltaY,
|
|
||||||
WORD buttonCount, DWORD extraInfo )
|
|
||||||
{
|
|
||||||
CONTEXT context;
|
|
||||||
|
|
||||||
if ( !MouseEventProc ) return;
|
|
||||||
|
|
||||||
TRACE( event, "(%04X,%d,%d,%d,%ld)\n", mouseStatus, deltaX, deltaY, buttonCount, extraInfo );
|
|
||||||
|
|
||||||
mouseStatus |= 0x8000;
|
|
||||||
deltaX = (((long)deltaX << 16) + screenWidth-1) / screenWidth;
|
|
||||||
deltaY = (((long)deltaY << 16) + screenHeight-1) / screenHeight;
|
|
||||||
|
|
||||||
memset( &context, 0, sizeof(context) );
|
|
||||||
CS_reg(&context) = SELECTOROF( MouseEventProc );
|
|
||||||
EIP_reg(&context) = OFFSETOF( MouseEventProc );
|
|
||||||
EAX_reg(&context) = mouseStatus;
|
|
||||||
EBX_reg(&context) = deltaX;
|
|
||||||
ECX_reg(&context) = deltaY;
|
|
||||||
EDX_reg(&context) = buttonCount;
|
|
||||||
ESI_reg(&context) = LOWORD( extraInfo );
|
|
||||||
EDI_reg(&context) = HIWORD( extraInfo );
|
|
||||||
|
|
||||||
Callbacks->CallRegisterShortProc( &context, 0 );
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/***********************************************************************
|
|
||||||
* GetMouseEventProc (USER.337)
|
|
||||||
*/
|
|
||||||
FARPROC16 WINAPI GetMouseEventProc(void)
|
|
||||||
{
|
|
||||||
HMODULE16 hmodule = GetModuleHandle16("USER");
|
|
||||||
return NE_GetEntryPoint( hmodule, NE_GetOrdinal( hmodule, "Mouse_Event" ));
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
/***********************************************************************
|
|
||||||
* Mouse_Event (USER.299)
|
|
||||||
*/
|
|
||||||
void WINAPI Mouse_Event( CONTEXT *context )
|
|
||||||
{
|
|
||||||
/* Register values:
|
|
||||||
* AX = mouse event
|
|
||||||
* BX = horizontal displacement if AX & ME_MOVE
|
|
||||||
* CX = vertical displacement if AX & ME_MOVE
|
|
||||||
* DX = button state (?)
|
|
||||||
* SI = mouse event flags (?)
|
|
||||||
*/
|
|
||||||
Window root, child;
|
|
||||||
int rootX, rootY, winX, winY;
|
|
||||||
unsigned int state;
|
|
||||||
|
|
||||||
if (AX_reg(context) & ME_MOVE)
|
|
||||||
{
|
|
||||||
/* We have to actually move the cursor */
|
|
||||||
TSXWarpPointer( display, rootWindow, None, 0, 0, 0, 0,
|
|
||||||
(short)BX_reg(context), (short)CX_reg(context) );
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
if (!TSXQueryPointer( display, rootWindow, &root, &child,
|
|
||||||
&rootX, &rootY, &winX, &winY, &state )) return;
|
|
||||||
if (AX_reg(context) & ME_LDOWN)
|
|
||||||
hardware_event( WM_LBUTTONDOWN, EVENT_XStateToKeyState( state ),
|
|
||||||
0L, winX, winY, GetTickCount(), 0 );
|
|
||||||
if (AX_reg(context) & ME_LUP)
|
|
||||||
hardware_event( WM_LBUTTONUP, EVENT_XStateToKeyState( state ),
|
|
||||||
0L, winX, winY, GetTickCount(), 0 );
|
|
||||||
if (AX_reg(context) & ME_RDOWN)
|
|
||||||
hardware_event( WM_RBUTTONDOWN, EVENT_XStateToKeyState( state ),
|
|
||||||
0L, winX, winY, GetTickCount(), 0 );
|
|
||||||
if (AX_reg(context) & ME_RUP)
|
|
||||||
hardware_event( WM_RBUTTONUP, EVENT_XStateToKeyState( state ),
|
|
||||||
0L, winX, winY, GetTickCount(), 0 );
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
/**********************************************************************
|
|
||||||
* EnableHardwareInput (USER.331)
|
|
||||||
*/
|
|
||||||
BOOL16 WINAPI EnableHardwareInput(BOOL16 bEnable)
|
|
||||||
{
|
|
||||||
BOOL16 bOldState = InputEnabled;
|
|
||||||
FIXME(event,"(%d) - stub\n", bEnable);
|
|
||||||
InputEnabled = bEnable;
|
|
||||||
return bOldState;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
/***********************************************************************
|
|
||||||
* SwapMouseButton16 (USER.186)
|
|
||||||
*/
|
|
||||||
BOOL16 WINAPI SwapMouseButton16( BOOL16 fSwap )
|
|
||||||
{
|
|
||||||
BOOL16 ret = SwappedButtons;
|
|
||||||
SwappedButtons = fSwap;
|
|
||||||
return ret;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
/***********************************************************************
|
|
||||||
* SwapMouseButton32 (USER32.537)
|
|
||||||
*/
|
|
||||||
BOOL32 WINAPI SwapMouseButton32( BOOL32 fSwap )
|
|
||||||
{
|
|
||||||
BOOL32 ret = SwappedButtons;
|
|
||||||
SwappedButtons = fSwap;
|
|
||||||
return ret;
|
|
||||||
}
|
|
||||||
|
@ -16,7 +16,7 @@
|
|||||||
#include "sysmetrics.h"
|
#include "sysmetrics.h"
|
||||||
#include "heap.h"
|
#include "heap.h"
|
||||||
#include "hook.h"
|
#include "hook.h"
|
||||||
#include "keyboard.h"
|
#include "input.h"
|
||||||
#include "spy.h"
|
#include "spy.h"
|
||||||
#include "winpos.h"
|
#include "winpos.h"
|
||||||
#include "atom.h"
|
#include "atom.h"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user