这是indexloc提供的服务,不要输入任何密码
Skip to content

Conversation

@KawaiiNahida
Copy link

No description provided.

@twaik
Copy link
Member

twaik commented Apr 11, 2024

Did you see the e.mouse.relative condition? It checks if event was sent to relative device or not. It exists for a reason. And making code explicitly ignore this is not a option.

@twaik twaik closed this Apr 11, 2024
@KawaiiNahida
Copy link
Author

Did you see the e.mouse.relative condition? It checks if event was sent to relative device or not. It exists for a reason. And making code explicitly ignore this is not a option.

I admit it's obviously not a good solution, but the current behavior of sending mouse scroll and movement via different devices causes the scroll to stop working when the mouse moves even slightly in most applications, it's so annoying.

I tried sending BUTTON_SCROLL to different devices, but I only received "RawMotion", and it seems that the applications do not respond to that. Additionally, I discovered that some devices' built-in touchpad gestures stop working when the pointer is captured by an app (for example, miui devices), and I will have to switch the pointer capture mode each time I switch between the mouse and built-in touchpad.

I've been running the modified version for almost a day and haven't found anything goes wrong with it, which is why I submitted the PR. I would appreciate it if there were other good solutions to solve this problem.

@twaik
Copy link
Member

twaik commented Apr 11, 2024

but the current behavior of sending mouse scroll and movement via different devices causes the scroll to stop working when the mouse moves even slightly in most applications, it's so annoying.

I'll take a look later.

I discovered that some devices' built-in touchpad gestures stop working when the pointer is captured by an app

They do not "stop working". Capturing pointer forces Android to send raw events to application. Which means application must handle all events and implement behaviour of touchpad not relying on OS behaviour.

I could fix this but I have no devices with real touchpads and do not have enough power or time for this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants