ther0n / UnnaturalScrollWheels

Invert scroll direction for physical scroll wheels while maintaining "Natural" scrolling for trackpads on MacOS

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Vertical scrolling reverted for each logged User

cptvita opened this issue · comments

When logged into two Users at the same time, the vertical switch toggle gets applied twice.
If logged only in one account where UnnaturalScrollWheels (USW) is running and vertical scrolling ticked, it works as expected. But when logged into another account with running USW with the same setting, the vertical scrolling is reverted twice, thus not working as one would expect.

Monterey 12.1 (21C52)

Are both users logged in at the same time? I only have my own personal account on my computer so it never really occure. Kinda weird that another user on the computer gets access to the input events of another user. I'm not sure how I'd be able to separate each user because if both users are logged in the app is running twice and it'd some how have to know the settings of the other user and counter act them or leave them the same. Settings for the app are stored in a plist file for that user and I sure hope one user can't access another users files without root...

Not sure if this is related but it sounds similar at least.

I've noticed this also seems to happen when you lock and unlock. Rebooting seems to fix the scrolling until you lock again.

I can confirm that as well. I have two users on my mac (both for me, but I had to do it like that for different settings and authorisations to work)
If I'm logged only to one (either one), the scrolling reversal works fine.
If I'm logged into both users (both have vertical scrolling reversal enabled), then I get regular scrolling behaviour. If I disable "invert vertical scrolling" on the active user, then I get inverted behaviour...
If I disable it on the second user as well, then back to normal (basic) behaviour. And both users experience that same behaviour at the same time.

I would assume the program keeps running under both users' credentials, each one reads the events and each one inverts it (effectively canceling out each other). You could add an check if the user is actually logged in (and not locked), then intercept the events. Otherwise, do nothing...