Skip to content

Adding Lifecycle Management #5

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

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

neon-izm
Copy link

Description

This PR implements lifecycle management for Unity within a SwiftUI application. The app now properly calls appropriate Unity framework methods in response to application state changes (active, inactive, background).

Suggestion

This PR also changed Unity camera's BackgroundColor (SolidColor:0,0,0,0), to implement transparent background.

also set transparent background unity camera
@neon-izm neon-izm changed the title Adding Lifecycle Management and Adding Lifecycle Management Mar 30, 2025
@bdeweygit
Copy link
Owner

What issues did you find that motivated adding these lifecycle calls? And what steps can we follow to reproduce the same?

Application lifecycle methods and listeners definitely appear in the code of the Unity build's generated Xcode project, but I'm guessing whatever lifecycle stuff Unity is doing internally is only designed for Objective-C/UIKit and not fully appropriate for how SwiftUI applications behave, is that right?

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.

2 participants