Skip to content

🐞 Avoid cursor stutter when suppressing Mission Control - #1133

Open
jvanderen1 wants to merge 5 commits into
mrkai77:developfrom
jvanderen1:fix/609-suppress-mission-control-stutter
Open

jvanderen1 wants to merge 5 commits into
mrkai77:developfrom
jvanderen1:fix/609-suppress-mission-control-stutter

Conversation

@jvanderen1

@jvanderen1 jvanderen1 commented Aug 9, 2026 •

Copy link
Copy Markdown
Contributor

Description

With Suppress Mission Control enabled, dragging a window to the top of the screen stutters. #609 reported this and was closed by turning the toggle off. The stutter is still in current develop when the toggle stays on. Tracked again in #1159.

Why: Loop keeps Mission Control closed by warping the cursor 1px down on every drag event (CGWarpMouseCursorPosition). That fights the upward drag, so the cursor thrashes.

Fix: Use an active event tap and rewrite the drag event’s location instead. macOS never sees a sustained top-edge hit, and the cursor is not warped.

Rewriting starts on the first drag event, before the window lookup finishes, because Mission Control can open on those events. If the drag is not a window, rewriting stops. The display is resolved with CoreGraphics on the event-tap thread rather than AppKit. Suppression still follows the Suppress Mission Control setting.

Fixes #1159

How has this been tested?

Local Debug build on macOS 27.0 (also checked earlier on macOS Tahoe):

  • Suppress on + drag to top and hold — cursor stays smooth, Mission Control does not open
  • Top snap preview still appears and applies on mouse up
  • Suppress off — Mission Control can still open from a top-edge window drag
  • Unit tests for which display edge is rewritten, including stacked displays and a shared corner

Worth a look on a second display, and while dragging something that is not a window (suppression should stop once that lookup fails).

Screencast

output.mp4

Checklist:

  • I have performed a self-review of my own code
  • I have made corresponding changes to the documentation if applicable
  • I have no unrelated changes in this PR.

Please describe to which degree, if any, an LLM was used in creating this pull request.

Cursor (Grok) helped investigate the stutter and draft the change in WindowDragManager, including the later event-tap hardening. I reviewed the code, confirmed it builds, and manually tested top-edge dragging before opening this PR.

jvanderen1 and others added 3 commits August 9, 2026 00:10
Rewrite top-edge drag events in an active tap instead of warping the cursor each frame, which caused the stutter reported in mrkai77#609.

Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
@jvanderen1

Copy link
Copy Markdown
Contributor Author

@mrkai77 I was wondering if you had q chance to see this PR? I have noticed the "Supress Misson Control" option in Loop was quite laggy on the top edge. This resolves that issue.

Rewrite top-edge drags before window lookup finishes, and resolve the display with CoreGraphics so the tap thread does not touch AppKit.

Co-authored-by: Cursor <cursoragent@cursor.com>

This branch has not been deployed

No deployments
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.

🐞 Cursor stutters at the top edge when Suppress Mission Control is on

1 participant