Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Delay in responding to Apple Magic Trackpad full haptic click event #169775

Closed
andrewbranch opened this issue Dec 21, 2022 · 10 comments
Closed

Delay in responding to Apple Magic Trackpad full haptic click event #169775

andrewbranch opened this issue Dec 21, 2022 · 10 comments
Assignees
Labels
info-needed Issue requires more information from poster

Comments

@andrewbranch
Copy link
Member

Does this issue occur when all extensions are disabled?: Yes

Version: 1.75.0-insider
Commit: edc432e
Date: 2022-12-16T05:22:34.551Z
Electron: 19.1.8
Chromium: 102.0.5005.167
Node.js: 16.14.2
V8: 10.2.154.15-electron.0
OS: Darwin x64 22.3.0
Sandboxed: Yes

Steps to Reproduce:

This is very strange, and unfortunately I don’t have a mouse on hand to test with. I use an Apple Magic Trackpad, and when I click anywhere in VS Code with a full press that triggers the haptic feedback on the trackpad, the response to that event is noticeably delayed (looks like a couple hundred ms to me). The same delay cannot be seen when interacting with the UI via the keyboard or with tap-to-click on the trackpad. This behavior only occurs in VS Code.

I recorded some video comparing the two kinds of clicks. You can see that tapping is faster throughout, but also that the delay when clicking to move the text insertion cursor seems to be roughly proportional to the distance that the cursor is moving. I should also note that I used the OS to highlight the clicks, as the clicks shown in VS Code’s Screencast Mode are also delayed.

slow.click.mov

I had been thinking that the render performance of VS Code has really been tanking lately, when in reality it’s just not processing my input! You have an opportunity here to improve perceived performance for perhaps all macOS trackpad users by 2x+ 😄

@andrewbranch
Copy link
Member Author

Hi all, I just want to emphasize how bad this problem is, and that it appears to be getting worse. You can now see it taking multiple seconds to move a text selection:

Screen.Recording.2023-02-07.at.12.11.46.PM.mov

VS Code is becoming increasingly painful for me to use at all. But it’s also bizarrely inconsistent—sometimes everything will be perfectly snappy, and then I’ll do something in another window, and after coming back, experience a huge amount of input lag. Is nobody else experiencing similar issues? Are there any logs or traces I can provide to help track the problem down? One quick look suggests that hardware acceleration could be involved: https://stackoverflow.com/questions/40390779/why-does-an-electron-js-app-respond-slow-to-user-inputs. Is there anything I can do to test that? Thank you!

@andrewbranch
Copy link
Member Author

Possibly related to #165016?

@tamuratak
Copy link
Contributor

Another is #148226.

How about disabling minimap?

Minimap is rendered on a canvas element. So, hardware acceleration could cause issues.

@andrewbranch
Copy link
Member Author

I will give that a shot. Yesterday I switched from Insiders to stable to see if it would repro in stable, and I didn’t have any problems for the rest of the day—but, I had the minimap disabled on stable.

@andrewbranch
Copy link
Member Author

After a few days of experience, I’m pretty sure the minimap is the culprit.

@clouedoc
Copy link

Super weird! That's happening to me too on Ventura.
Minimap was already disabled. Updating fixed the issue for me

@deepak1556
Copy link
Collaborator

I don't have the hardware to verify this issue, @andrewbranch is this still an issue in latest stable with minimap enabled ?

@deepak1556 deepak1556 added the info-needed Issue requires more information from poster label Dec 5, 2023
@andrewbranch
Copy link
Member Author

Since filing this issue, I got a new computer with a different processor architecture and completely stopped using the minimap. I can reenable the minimap for a while and see how it goes, but if it doesn’t repro, that won’t exculpate Intel Macs.

@vscodenpa
Copy link

Hey @deepak1556, this issue might need further attention.

@andrewbranch, you can help us out by closing this issue if the problem no longer exists, or adding more information.

@andrewbranch
Copy link
Member Author

I no longer have the hardware to tell if this will repro or not, so closing.

@andrewbranch andrewbranch closed this as not planned Won't fix, can't repro, duplicate, stale Feb 26, 2024
@microsoft microsoft locked and limited conversation to collaborators Jun 11, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
info-needed Issue requires more information from poster
Projects
None yet
Development

No branches or pull requests

7 participants