From b1e5bd8d67179f24f3603fad22ea928357f6b164 Mon Sep 17 00:00:00 2001 From: Javier Date: Sun, 30 Aug 2026 02:52:49 +0200 Subject: update es translation and add error message for wheels on serial mice --- mousmain.c | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) (limited to 'mousmain.c') diff --git a/mousmain.c b/mousmain.c index a7298a5..23dd2e3 100644 --- a/mousmain.c +++ b/mousmain.c @@ -37,7 +37,7 @@ static nl_catd cat; #if USE_WHEEL -static bool detect_wheel(LPTSRDATA data) +static bool detect_ps2_wheel(LPTSRDATA data) { // Do a quick check for a mouse wheel here. // The TSR will do its own check when it is reset anyway @@ -63,7 +63,12 @@ static int set_wheel(LPTSRDATA data, bool enable) data->usewheel = enable; if (data->usewheel) { - if (!detect_wheel(data)) { + if (data->port == 0) { + if (!detect_ps2_wheel(data)) { + fprintf(stderr, _(3, 0, "Could not find PS/2 wheel mouse\n")); + } + } else { + // TODO Serial does not support wheels yet fprintf(stderr, _(3, 0, "Could not find PS/2 wheel mouse\n")); } } else { @@ -294,7 +299,7 @@ static int configure_driver_ps2(LPTSRDATA data) #if USE_WHEEL // Let's utilize the wheel by default data->usewheel = true; - detect_wheel(data); + detect_ps2_wheel(data); #else // Without ImEX/wheel detection, hardcode number of buttons data->num_buttons = 3; -- cgit v1.2.3