Skip to content

can hide status bar on iOS #17179

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

Merged

Conversation

mockersf
Copy link
Member

@mockersf mockersf commented Jan 5, 2025

Objective

  • I want to hide the clock and the battery indicator on iOS

Solution

  • Add the platform specific property prefers_status_bar_hidden on Window creation, and map it to with_prefers_status_bar_hidden in winit.

Testing

  • Tested on iOS

@mockersf mockersf added A-Windowing Platform-agnostic interface layer to run your app in O-iOS Specific to the iOS mobile operating system labels Jan 5, 2025
@BenjaminBrienen BenjaminBrienen added D-Straightforward Simple bug fixes and API improvements, docs, test and examples S-Needs-Review Needs reviewer attention (from anyone!) to move forward labels Jan 6, 2025
Copy link
Contributor

@BenjaminBrienen BenjaminBrienen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks right, haven't tested

@alice-i-cecile alice-i-cecile added S-Ready-For-Final-Review This PR has been approved by the community. It's ready for a maintainer to consider merging it and removed S-Needs-Review Needs reviewer attention (from anyone!) to move forward labels Jan 6, 2025
Copy link
Contributor

@eero-lehtinen eero-lehtinen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Haven't tested this PR but have used the same winit function in a Bevy app before and it has always worked.

Winit has set_prefers_status_bar_hidden so that value could technically also be updated at runtime.

@alice-i-cecile alice-i-cecile added this pull request to the merge queue Jan 6, 2025
Merged via the queue into bevyengine:main with commit 94b9fe3 Jan 6, 2025
34 checks passed
github-merge-queue bot pushed a commit that referenced this pull request Jan 7, 2025
# Objective

- Followup on
#17179 (review)
- Can show / hide home indicator / status bar during runtime

## Solution

- react on window change

## Testing

- Tested on iOS
mrchantey pushed a commit to mrchantey/bevy that referenced this pull request Feb 4, 2025
# Objective

- I want to hide the clock and the battery indicator on iOS

## Solution

- Add the platform specific property `prefers_status_bar_hidden` on
Window creation, and map it to `with_prefers_status_bar_hidden` in
winit.

## Testing

- Tested on iOS
mrchantey pushed a commit to mrchantey/bevy that referenced this pull request Feb 4, 2025
…e#17204)

# Objective

- Followup on
bevyengine#17179 (review)
- Can show / hide home indicator / status bar during runtime

## Solution

- react on window change

## Testing

- Tested on iOS
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-Windowing Platform-agnostic interface layer to run your app in D-Straightforward Simple bug fixes and API improvements, docs, test and examples O-iOS Specific to the iOS mobile operating system S-Ready-For-Final-Review This PR has been approved by the community. It's ready for a maintainer to consider merging it
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants