⚡ Refactor WindowEngine to operate on non-main actor by default#964
Merged
Conversation
0930f60 to
81e8b1d
Compare
Contributor
|
🚧 Development Build Finished
|
4 tasks
There was a problem hiding this comment.
Pull request overview
This PR refactors the window resizing system to improve UI responsiveness by moving window operations off the main actor. The key changes split window frame setting into synchronous and asynchronous variants, allowing animations to run without blocking the UI.
- Replaced
setFrame(frame, animate: bool)with separatesetFrame(frame)andsetFrameAnimated(frame, bounds:)calls - Introduced conditional logic throughout StashManager to choose between animated and non-animated variants
- Wrapped
activate()calls inTask { @MainActor in }blocks to ensure proper actor isolation
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
SenpaiHunters
approved these changes
Jan 8, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Task.detachedto perform window resizing in the background, reducing UI lag that occurred when everything ran on the main actor.start()on the main actor, removing the need to manually manage a run loop on a global actor.