lan-mouse icon indicating copy to clipboard operation
lan-mouse copied to clipboard

Jumping Mousewheel and no Double Click MacOS Client

Open tobiashugo opened this issue 2 months ago • 19 comments

Using a Windows 11 (newest updates) as server and MacOS client (15.6.1) double clicks on the MacOS client are not recognized. The scroll wheel jumps several lines instead of one.

I didn't find these issues, but am a GitHub noob, please delete/ignore if this post is irrelevant.

Best regards,

Tobias

tobiashugo avatar Oct 23 '25 20:10 tobiashugo

Could you clarify what you mean by server and client? I'm assuming, you are using the Win11 device to control your mac, is that correct?

feschber avatar Oct 24 '25 13:10 feschber

That is correct. If I can provide any more info or debug logs etc. let me know.

The software otherwise feels great, no menu popup on long right mouse button presses. That bug is bothering me with every other solution I've tried so far (barrier and forks, synergy 3, sharemouse and few others). No mouse cursor lags, no mouse pointer appearing in the middle of the client screen.

tobiashugo avatar Oct 24 '25 13:10 tobiashugo

I will see if I can reproduce it!

In case you haven't, you may want to try deskflow as well :)

feschber avatar Oct 24 '25 13:10 feschber

@nbolton, do you know about that long right button press issue?

feschber avatar Oct 24 '25 13:10 feschber

@nbolton, do you know about that long right button press issue?

That bug is long standing since I first started using Sharemouse several years ago and has been consistent for me for all iterations of KVM Software. Synergy and Sharemouse support shrugged and couldn't provide a solution. Not having that behavior is new to me. The reason I started looking for a different solution (tried deskflow as well) is, that all of a sudden the cursor jumps to the center of the mac screen when switching to the client in normal speed and not very slowly. Probably introduced by some mac or windows updates, as it now happens with all synergy 1/barrier forks and also synergy 3, yet not lan-mouse.

tobiashugo avatar Oct 24 '25 13:10 tobiashugo

The software otherwise feels great, no menu popup on long right mouse button presses.

Would you mind opening a bug report in Deskflow if it happens there? https://github.com/deskflow/deskflow/issues

@nbolton, do you know about that long right button press issue?

It doesn't ring a bell, but it sounds like @tobiashugo has been pretty thorough in their testing.

Synergy [...] support shrugged

Oh dear, would you be against sharing the support ticket number so I can dig a bit deeper? The more info I have the more I can understand the issue.

(tried deskflow as well) is, that all of a sudden the cursor jumps to the center of the mac screen when switching to the client in normal speed and not very slowly.

Now this one does ring a bell. This may be a bit off-topic but I don't suppose you have a Deskflow issue link?

yet not lan-mouse

Very interesting. I haven't yet made time to dig into the LAN Mouse source code for macOS, but I'm guessing newer/different API functions are used. Some of Synergy/Deskflow (and likely Synergy forks/clones) uses older deprecated functions which code needs modernizing.

@feschber Do you have any knowledge [roughly] of what macOS API functions LAN Mouse uses that Synergy/Deskflow doesn't?

nbolton avatar Oct 24 '25 16:10 nbolton

@nbolton lan-mouse uses CGEventPost with cghidEventTap: https://github.com/feschber/lan-mouse/blob/main/input-emulation/src/macos.rs

feschber avatar Oct 24 '25 16:10 feschber

lan-mouse uses CGEventPost with cghidEventTap

Ah, same: https://github.com/deskflow/deskflow/blob/c91b2803972a4d913d99245f745cb1f2f4702574/src/lib/platform/OSXKeyState.cpp#L587

nbolton avatar Oct 24 '25 16:10 nbolton

From the description, it sounds like the mouse jumping to the center of the screen could be caused by input-emulation code not waiting for the capture to warp the cursor back to its release position, causing the emulation code to offset from the captured point (which I'm guessing is in the middle of the screen?) instead of the barrier. This would at least explain why slow mouse movement would not trigger the issue. Just a guess though.

In LanMouse this does not happen because the cursor is currently not warped at all on input capture begin / end.

feschber avatar Oct 27 '25 10:10 feschber

#337 should fix the scrolling. The double click problem is a bit more complicated, apparently on MacOS, a flag must be manually set for a double click to be registered.

I also noticed that for some reason control+up arrow does not seem to trigger the overview Window. I will investigate that as well.

feschber avatar Oct 29 '25 12:10 feschber

#338 should fix the double clicking :)

feschber avatar Oct 29 '25 15:10 feschber

I can confirm both issues have been remedied BUT now the bloody right mouse button menu pops up after long click :( This was introduced with #338, #337 was fine I'd rather loose double click again and not have that popup. Left press and return is more convenient for me. Fortunately Trash bin kept the #337 binary :)

tobiashugo avatar Oct 29 '25 17:10 tobiashugo

@tobiashugo could you elaborate a bit more what menu you mean and when exactly it happens? I can't seem to replicate this. Do you have any other software installed that may be interfering?

feschber avatar Oct 29 '25 22:10 feschber

@tobiashugo can you check the latest pre-release? It might have fixed this issue but I'm just guessing since I'm unable to properly test this ...

feschber avatar Oct 29 '25 23:10 feschber

(its going to take a few minutes for it to release)

feschber avatar Oct 29 '25 23:10 feschber

This does actually help, but it somehow messes up the middle mouse button. I'm using Aycan PACS Viewer (an older fork of Osirix, Horos is a free newer fork). When using the middle mouse button on an image window I have not prior selected with left or right mouse button, it first propagates mouse movement and mixed button usage (e.g. pushing middle button but it sometimes uses the middle or left mouse button function) to the prior selected image pane. Left and right mouse button function correctly using the image pane under the cursor. After this bug happens, mouse functions are messed up until pushing all mouse buttons and all special keys. Otherwise it sometimes selects does things...I don't even know how to do even if I wanted (probs some mouse/key combinations I'm not aware of). Also mouse scroll wheel direction is inverted, the setting natural scrolling has no effect on this. I will try the older build after getting home (around 19.00) just to double check I didn't miss this bug before.

tobiashugo avatar Oct 30 '25 07:10 tobiashugo

@tobiashugo do you have some sort of dummy data set I could use for Horos, and a quick explanation of what you are doing? It was the easiest of the three for me to install for testing.

The inverted scrolling is definitely an Issue, I think it might be best to invert by default on MacOS (#339)

feschber avatar Oct 30 '25 10:10 feschber

You can use the sample Images from http://deckard.mc.duke.edu/~samei/tg18 If you need real world anonymized datasets (maybe out of interest?) I can provide a pcloud link

tobiashugo avatar Oct 30 '25 11:10 tobiashugo

By the way, I would still like your solution going into deskflow. For me that mouse button behaviour went from major nuisance I learned to work around somehow to a minor issue I rarely even noticed anymore (short left button press before middle button usage has become normal). Maybe make it a configurable option?

tobiashugo avatar Nov 04 '25 06:11 tobiashugo