rxhanson / Multitouch-Community

Issue and feature request tracking for the Multitouch app
https://multitouch.app
38 stars 0 forks source link

Multitouch app causes severe unresponsiveness when using mac Catalyst apps with trackpad. #158

Closed upstroke-version closed 1 year ago

upstroke-version commented 1 year ago

Lots of modern macOS apps are made with Mac Catalyst, such apps are Messages, Weather, Home, News, Stocks, Books, etc. I’ve always hated Catalyst apps because they were unresponsiveness to clicks, I had to click 2~4times to do register a click and when it did registered a click, the animations felt so janky. I’ve always thought this was macOS bug, but it seems like multitouch app is causing this issue.

When I quit multitouch, the issue goes away, and when I launch multitouch, It comes back. The issue only occurs when using Catalyst app with trackpad and does not occur when using with magic mouse.

Steps to reproduce:

  1. disable tap to click on both system settings and multitouch's setting.
  2. launch multitouch.
  3. launch any Catalyst app(Messages, Weather, Home, News, Stocks, Books, etc).
  4. try clicking stuff like sidebar items with trackpad(with click, not tap).
  5. clicks won't register well

macOS version: Ventura 13.3.1 (this issue happened at least since Monterey)

multitouch version: 1.27.11

rxhanson commented 1 year ago

Thanks for reporting. Sorry, this would be quite irritating.

I can't reproduce it. Unfortunately, this type of issue points to the macOS event stream, and it's not easy to determine what combination of factors could come together to cause it.

The first thing to try is to uncheck the box for "Avoid private framework" in the settings tab. This will restart the app and will obtain touch information from the same place where the Magic Mouse touch data is coming from. Let me know what you find.

upstroke-version commented 1 year ago

I tried both checking and unchecking "Avoid private framework" and the issue is not affected by this setting.

I'm not sure what would be the unique factor of my machine. I've reinstalled macOS few months ago and this issue existed before and after the reinstall. So it can't be the OS. I don't have any other utilities related to mouse & keyboard customization/automation other than Multitouch. maybe I could try booting into safe mode and only launch multitouch app and check if issue persists.

upstroke-version commented 1 year ago

Tested on safe mode, Issue persists when multitouch is running and other 3rd party apps are not running. So other 3rd party apps are probably not the reason that your machine can't reproduce.

upstroke-version commented 1 year ago

Probably not meaningful info for debugging but checking "Disable Gestures" on multitouch's menu seems to remove this issue, having same effect as quitting multitouch app.

rxhanson commented 1 year ago

Thanks for the update. Let me see if I can reproduce it with your config. In the menu bar menu, select Help > Debug > Copy debug info to clipboard.

upstroke-version commented 1 year ago

Multitouch: 1.27.11 (166) macOS: Version 13.3.1 (Build 22E261) Model: MacBookAir10,1 Devices: ["magicTrackpad2:216172782131609600:17825792","internalTrackpad2:144115188075855909:37","magicMouse:288230378145112812:1993401068"] Multitouch Configuration: [{"gid":{"gesture":"oneForceBottomLeft","appId":"~browsers"},"r":{"focus":false,"type":1,"keyCode":45,"modifierFlags":1179648}},{"gid":{"gesture":"onePlusRightMouse","appId":""},"r":{"type":3,"action":306}},{"gid":{"gesture":"twoPlusLeft","doubleTap":true,"appId":""},"r":{"focus":false,"type":1,"keyCode":13,"modifierFlags":1048576}},{"gid":{"gesture":"twoPlusRight","doubleTap":true,"appId":""},"r":{"type":2,"action":230}},{"gid":{"gesture":"twoPlusCenter","doubleTap":true,"appId":""},"r":{"focus":false,"type":1,"keyCode":46,"modifierFlags":1048576}},{"gid":{"gesture":"onePlusLeftNear","doubleTap":true,"appId":"~tabbedApps"},"r":{"type":5,"action":501,"flag":false}},{"gid":{"gesture":"onePlusRightNear","doubleTap":true,"appId":"~tabbedApps"},"r":{"type":5,"action":500,"flag":false}},{"gid":{"gesture":"onePlusLeftNearMouse","appId":""},"r":{"type":5,"action":501,"flag":false}},{"gid":{"gesture":"onePlusRightNearMouse","appId":""},"r":{"type":5,"action":500,"flag":false}},{"gid":{"gesture":"threeClickMouse","appId":""},"r":{"type":2,"action":213}},{"gid":{"gesture":"twoPlusCenterMouse","appId":""},"r":{"focus":false,"type":1,"keyCode":46,"modifierFlags":1048576}},{"gid":{"gesture":"twoPlusLeftMouse","appId":""},"r":{"type":2,"action":214}},{"gid":{"gesture":"twoPlusRightMouse","appId":""},"r":{"type":2,"action":230}},{"gid":{"gesture":"threeTapMouse","appId":""},"r":{"type":17,"id":"551B655F-E649-452E-9940-38EA34E64EF6"}},{"gid":{"gesture":"oneCenterClickMouse","appId":""},"r":{"type":2,"action":234}},{"gid":{"gesture":"oneForceTopRight","appId":""},"r":{"id":"3B53EE05-6BE0-4FD0-BCE6-113C5D7017CB","output":false,"type":16,"action":1600}},{"gid":{"gesture":"oneForceBottomRight","appId":""},"r":{"id":"31E409DB-126D-4891-9EEA-60D0ABFAAF59","output":false,"type":16,"action":1600}},{"gid":{"gesture":"threeTap","appId":""},"r":{"focus":false,"type":1,"keyCode":29,"modifierFlags":1048576}},{"gid":{"gesture":"threeOneUp","appId":""},"r":{"id":"9A4F2984-0A38-4523-A8EB-77FACA4CC1EF","output":false,"type":16,"action":1600}},{"gid":{"gesture":"threeOneDown","appId":""},"r":{"id":"2A3E3284-DF5A-45AD-9E52-D124469CEE88","output":false,"type":16,"action":1600}},{"gid":{"gesture":"threeTapMouse","doubleTap":true,"appId":""},"r":{"focus":true,"type":1,"keyCode":115,"modifierFlags":0}},{"gid":{"gesture":"threeTap","doubleTap":true,"appId":""},"r":{"focus":false,"type":1,"keyCode":115,"modifierFlags":0}},{"gid":{"gesture":"oneBottomRight","doubleTap":true,"appId":""},"r":{"id":"436F4B48-7C0A-426A-864F-0371548CA157","output":true,"type":16,"action":1600}},{"gid":{"gesture":"oneBottomLeft","doubleTap":true,"appId":""},"r":{"focus":false,"type":1,"keyCode":17,"modifierFlags":1048576}},{"gid":{"gesture":"onePlusLeftMouse","appId":""},"r":{"type":3,"action":307}},{"gid":{"gesture":"oneTapLeftMouse","appId":""},"r":{"type":3,"action":307}},{"gid":{"gesture":"oneTopLeft","doubleTap":true,"appId":""},"r":{"type":2,"action":219}},{"gid":{"gesture":"oneTopRight","doubleTap":true,"appId":""},"r":{"id":"F12483E1-64E1-4F3C-BBB9-5A2DA1863CEA","output":false,"type":16,"action":1600}},{"gid":{"gesture":"oneCenterClickMouse","flags":1048576,"appId":""},"r":{"type":3,"action":310}},{"gid":{"gesture":"oneTapRightMouse","appId":""},"r":{"type":3,"action":306}},{"gid":{"gesture":"oneTapRightMouse","flags":1048576,"appId":"~tabbedApps"},"r":{"type":5,"action":504,"flag":false}},{"gid":{"gesture":"oneTapRightMouse","flags":1572864,"appId":""},"r":{"focus":false,"type":1,"keyCode":45,"modifierFlags":1048576}},{"gid":{"gesture":"oneTapRightMouse","flags":1835008,"appId":"~browsers"},"r":{"focus":false,"type":1,"keyCode":45,"modifierFlags":1179648}},{"gid":{"gesture":"oneTapRightMouse","flags":1835008,"appId":"com.apple.Music"},"r":{"focus":false,"type":1,"keyCode":3,"modifierFlags":1179648}},{"gid":{"gesture":"oneTapRightMouse","flags":1835008,"appId":"com.apple.finder"},"r":{"focus":false,"type":1,"keyCode":34,"modifierFlags":1048576}},{"gid":{"gesture":"oneTapRightMouse","flags":1835008,"appId":"com.apple.dt.Xcode"},"r":{"focus":false,"type":1,"keyCode":18,"modifierFlags":1179648}},{"gid":{"gesture":"oneTapRightMouse","appId":""},"r":{"type":3,"action":306}},{"gid":{"gesture":"twoLeftEdgeSwipe","appId":""},"r":{"type":12}},{"gid":{"gesture":"threeTap","flags":131072,"doubleTap":true,"appId":""},"r":{"focus":false,"type":1,"keyCode":125,"modifierFlags":1048576}},{"gid":{"gesture":"onePlusLeft","doubleTap":true,"appId":""},"r":{"id":"31CA01EC-72C3-41BD-A2A6-B19AC1B3F590","output":false,"type":16,"action":1600}},{"gid":{"gesture":"onePlusRight","doubleTap":true,"appId":""},"r":{"id":"8709416D-EFF4-4D74-84A9-168C6DB30A1B","output":false,"type":16,"action":1600}},{"gid":{"gesture":"threePlusLeft","doubleTap":true,"appId":""},"r":{"id":"35363AD5-F7CB-4111-B7AC-202CB001F587","output":false,"type":16,"action":1600}},{"gid":{"gesture":"threePlusRight","doubleTap":true,"appId":""},"r":{"id":"590AAA12-61E0-455B-943D-F382697F9282","output":false,"type":16,"action":1600}},{"gid":{"gesture":"threeTapMouse","flags":131072,"doubleTap":true,"appId":""},"r":{"focus":false,"type":1,"keyCode":125,"modifierFlags":1048576}},{"gid":{"gesture":"fourOneUp","appId":""},"r":{"type":15,"action":1507}},{"gid":{"gesture":"fourOneLeft","appId":""},"r":{"type":15,"action":1505}},{"gid":{"gesture":"fourOneRight","appId":""},"r":{"type":15,"action":1506}},{"gid":{"gesture":"fourOneDown","appId":""},"r":{"type":15,"action":1517}},{"gid":{"gesture":"threeOneLeft","appId":""},"r":{"id":"3454EAF3-4217-4A12-8357-1AC5002C6267","output":false,"type":16,"action":1600}},{"gid":{"gesture":"threeOneRight","appId":""},"r":{"id":"6C5A8042-2EDC-41CE-B62F-223DDB4992CE","output":false,"type":16,"action":1600}},{"gid":{"gesture":"oneForceBottomLeft","appId":"com.apple.Music"},"r":{"focus":false,"type":1,"keyCode":3,"modifierFlags":1179648}},{"gid":{"gesture":"oneForceBottomLeft","appId":"com.apple.finder"},"r":{"focus":false,"type":1,"keyCode":34,"modifierFlags":1048576}},{"gid":{"gesture":"oneForceBottomLeft","appId":"com.apple.dt.Xcode"},"r":{"focus":false,"type":1,"keyCode":18,"modifierFlags":1179648}},{"gid":{"gesture":"oneForceTopLeft","appId":""},"r":{"id":"A3A7D393-0CC1-48A7-97DB-2DAB6D49165B","output":false,"type":16,"action":1600}},{"gid":{"gesture":"twoPlusLeft","doubleTap":true,"appId":""},"r":{"id":"D2285F89-6F01-463F-9156-EAD62447EF98","output":false,"type":16,"action":1600}},{"gid":{"gesture":"threeForce","appId":""},"r":{"type":2,"action":213}},{"gid":{"gesture":"threeForce","appId":""},"r":{"id":"E7143442-2623-493F-A78F-06AB022397C0","output":false,"type":16,"action":1600}},{"gid":{"gesture":"threeClick","appId":""},"r":{"type":2,"action":200}},{"gid":{"gesture":"oneClickTopLeft","appId":""},"r":{"type":2,"action":240}},{"gid":{"gesture":"oneClickTopRight","appId":""},"r":{"id":"6C7DF50F-A175-4769-BF1A-B3E5B077997A","output":false,"type":16,"action":1600}},{"gid":{"gesture":"oneClickBottomLeft","appId":""},"r":{"focus":false,"type":1,"keyCode":45,"modifierFlags":1048576}},{"gid":{"gesture":"oneClickBottomRight","appId":""},"r":{"id":"1DE77829-1FD1-4CA6-B61E-BD9478F979FE","output":false,"type":16,"action":1600}}]

upstroke-version commented 1 year ago

To reproduce, I recommend apps like Messages and Weather, those two app show the issue very well in my experience. If you still can't reproduce it, try rapdly clicking different sidebar items, for example try to click every item in the sidebar as fast as you can.

rxhanson commented 1 year ago

Unfortunately, I still can't reproduce it. I tried on my M1 Mac on 13.3.1 and my old Intel Mac on 12.6.5. Without being able to reproduce it, the only thing that can help is to get some logging in. I'll have to give this some thought on where to get some logging in, and will let you know when I can get a debug build out.

alinnert commented 1 year ago

Maybe I can provide more information on this. I have the same issue on a M1 MacBook Air (13.4), using the internal and an external trackpad. I also have a M1 Mac mini which I've just updated from macOS 13.2.1 to 13.4. This problem does not occur on both versions. It seems Multitouch gestures don't work if I'm controlling another device using Universal Control. This means Catalyst apps always work nicely if controlled from another device.

So, I can replicate both scenarios. Are there some tests I can do to track down the issue?

alinnert commented 1 year ago

Okay, I think I've found something. I can also get rid of the issue if I disable the setting "Drag window to screen edge to snap". The issue only appears if this option is enabled and at least one gesture is defined and gestures are enabled. This way I can also reproduce the issue on my Mac mini. I hope this helps.

rxhanson commented 1 year ago

@alinnert Thanks! This does help. If you have Rectangle installed and would be up for testing for me, I wonder if you would have the issue with Rectangle's drag window to screen edge to snap setting enabled while Multitouch is running. Just trying to narrow things down a bit. I'm away from my Mac until tomorrow, when I'll be able to test things out myself.

alinnert commented 1 year ago

Just tested it. Using Rectangle next to Multitouch does not cause this issue. 👍

rxhanson commented 1 year ago

I tested this out using @upstroke-version's config, I was able to narrow it down to the combination of one finger Force Touch gestures configured in Multitouch with the drag to screen edge snap enabled. I have some ideas to try out to see if I can fix it. @alinert, do you have one finger Force Touch gestures configured?

alinnert commented 1 year ago

@rxhanson No, all I've configured is "Tap with three touches" -> "Middle Click". I've tried a few other gestures but it happens for all I try.

But I've found a very strange exception: If I configure "Tap with three touches" -> "Browser > Switch tabs right" interacting with a Catalyst app causes one single lag and then disables all gestures like they were crashing - but Multitouch preferences are still responsive. So, this can be fixed by removing and re-adding the mapping or restarting Multitouch. Disabling and enabling all gestures does not fix it though. But: This does not happen anymore if I add a second gesture (I've added "Rest two, tap one to the left" -> "Middle Click").

I hope this is just a side effect of the original issue. But it seems that the assigned action also does have some sort of effect.

rxhanson commented 1 year ago

@alinnert thanks for the additional info.

Up for trying out a beta?

https://multitouch.app/beta/multitouch1.27.13.dmg

upstroke-version commented 1 year ago

It looks like the issue is solved in this new beta! thanks for @alinnert for investigating this issue further and @rxhanson for great work! I was using janky workaround which was quitting multitouch when catalyst apps were launched using other 3rd party utility.

alinnert commented 1 year ago

@rxhanson Yes, I can also confirm the issue is gone. As well as the crash regarding the "Switch tabs right" action. 👍

rxhanson commented 1 year ago

Thanks, both for the quick test. Glad things are looking good! I am getting ready to roll out an official release (1.27.14) that will cover some extra edge cases not covered in the beta (you're fine using the beta until then in your cases). Once that's out, you will be able to update to it from within the app or at https://multitouch.app. Just waiting on Apple's servers since something must be down for WWDC today. I will close this issue when that release is live.