VNC and Win32 mouse clean-ups.

This commit is contained in:
OBattler
2023-08-13 18:25:56 +02:00
parent d90592b291
commit 976fe24ba1
4 changed files with 2 additions and 22 deletions

View File

@@ -156,7 +156,7 @@ mouse_clear_coords(void)
mouse_z = 0;
}
static void
void
mouse_clear_buttons(void)
{
mouse_buttons = 0x00;

View File

@@ -78,6 +78,7 @@ extern const device_t mouse_wacom_artpad_device;
extern void mouse_clear_x(void);
extern void mouse_clear_y(void);
extern void mouse_clear_coords(void);
extern void mouse_clear_buttons(void);
extern void mouse_subtract_x(int *delta_x, int *o_x, int min, int max, int abs);
extern void mouse_subtract_y(int *delta_y, int *o_y, int min, int max, int invert, int abs);
extern void mouse_subtract_coords(int *delta_x, int *delta_y, int *o_x, int *o_y,

View File

@@ -46,15 +46,6 @@ static int ptr_x;
static int ptr_y;
static int ptr_but;
typedef struct {
int buttons;
int dx;
int dy;
int dwheel;
} MOUSESTATE;
static MOUSESTATE ms;
#ifdef ENABLE_VNC_LOG
int vnc_do_log = ENABLE_VNC_LOG;
@@ -153,7 +144,6 @@ vnc_newclient(rfbClientPtr cl)
ptr_y = allowedY / 2;
mouse_clear_coords();
mouse_clear_buttons();
memset(&ms, 0, sizeof(MOUSESTATE));
/* We now have clients, un-pause the emulator if needed. */
vnc_log("VNC: unpausing..\n");

View File

@@ -32,15 +32,6 @@
int mouse_capture;
typedef struct {
int buttons;
int dx;
int dy;
int dwheel;
} MOUSESTATE;
MOUSESTATE mousestate;
void
win_mouse_init(void)
{
@@ -56,8 +47,6 @@ win_mouse_init(void)
ridev.usUsage = 0x02;
if (!RegisterRawInputDevices(&ridev, 1, sizeof(ridev)))
fatal("plat_mouse_init: RegisterRawInputDevices failed\n");
memset(&mousestate, 0, sizeof(MOUSESTATE));
}
void