Skip to content

About

Provides access to iOS native AppDelegate calls from inside Bevy Apps

Topics

Resources

Stars

12 stars

Watchers

1 watching

Forks

Latest commit

 

History

15 Commits

Folders and files

Repository files navigation

bevy_ios_app_delegate

crates.io docs.rs discord

Read more about usage and examples in this blog post.

Features

  • trigger AppDelegateCall::OpenURL event if app was opened or forgrounded based on a click on a URL schema
  • trigger AppDelegateCall::UniversalLink event if app was opened or forgrounded based on a click on a universal link: a plain https:// address of a domain the app claims through its associated-domains entitlement and an apple-app-site-association file served by that domain
  • UIScene life cycle support: apps built with the iOS 27 SDK must adopt it or fail to launch, which winit does not do yet (winit#4224)

Usage

  1. Make sure your winit dependency is at least 0.30.10 (where winit stopped implementing AppDelegate itself)
  2. Add dependency cargo add bevy_ios_app_delegate
  3. Register plugin app.add_plugins((IosAppDelegatePlugin));
  4. Add observer: app.add_observer(|trigger: On<AppDelegateCall>| {});

UIScene life cycle

Add this to your Info.plist to opt in. The plugin then provides the scene delegate (no UISceneConfigurations needed) and moves winit's window onto the scene:

<key>UIApplicationSceneManifest</key>
<dict>
    <key>UIApplicationSupportsMultipleScenes</key>
    <false/>
</dict>

Our Other Crates

Bevy version support

bevy crate
0.20 0.6,main
0.19 0.5
0.18 0.4
0.17 0.3
0.16 0.2
0.15 0.1

License

All code in this repository is dual-licensed under either:

at your option. This means you can select the license you prefer.

Your contributions

Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.

About

Provides access to iOS native AppDelegate calls from inside Bevy Apps

Topics

Resources

Stars

12 stars

Watchers

1 watching

Forks

Releases

Packages

Used by

Contributors

Languages