Draft
Conversation
Contributor
|
what is the problem with rerendering on UIKit and WinUI? /cur |
Contributor
Author
|
AFAIK there isn’t any, I just haven’t gotten around to it yet. |
Contributor
|
ah, okay :) |
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.
Adds a
scenePhaseenvironment value and associated types and backend functions.Appstruct, it returnsactiveif the app as a whole is active, orinactiveotherwise. (For GTK and WinUI, this simply checks if any of the app's windows are active; for AppKit and UIKit it checks the appropriate property ofNS/UIApplication.shared.)View, it returnsactiveif the enclosing window is active, orinactiveotherwise.This resolves #488.
Currently, there are only two scene states:
activeandinactive. We can consider adding abackgroundstate to match SwiftUI, though that'd require some extra bikeshedding on the exact behavior ofbackgroundon desktop platforms -- personally I'd prefer to leave that for a future PR, but if it's important enough to add it now we can add it now.Implemented backends
The property itself
Rerendering when scene phase changes