Skip to content

Fix Sheet system bar visibility reads on legacy Android - #70

Merged
Moriafly merged 1 commit into
mainfrom
fix/sheet-system-bars-android10
Oct 30, 2026
Merged

Moriafly merged 1 commit into
mainfrom
fix/sheet-system-bars-android10

Conversation

@Moriafly

Copy link
Copy Markdown
Owner

On Android 6–10 (API 23–29), root window insets can reserve layout space even when system bars are hidden. Convert the native insets with the owner View so AndroidX includes the window's hide flags when a Sheet inherits its opening visibility.

Add one regression that checks actual System UI visibility for bottom and floating Sheets. The existing full owner-isolation test now runs on API 30+: legacy Dialog focus changes can still clear the host's hide flags. This limitation and the host focus workaround are documented in code comments. The Dialog host is unchanged; README is unchanged.

Public API changes: None.

Validation:

  • Debug and Android test APK assembly passed.
  • Android 10 (API 29): 4 targeted interaction tests passed.
  • Android 12 (API 31): 4 targeted interaction tests passed.
  • git diff --check passed.

Convert native root insets with the owner View so AndroidX accounts for
legacy system UI hide flags instead of treating reserved layout space as
visible bars on API 23-29. Keep the existing Dialog host and public API.

Add a real System UI regression for bottom and floating Sheets. Restrict
the existing full owner-isolation test to API 30+, and document legacy
focus propagation and the host-side focus workaround in code comments.

Validation: debug and Android test APK assembly passed. Four targeted
tests passed on Android 10 (API 29), and four passed on Android 12
(API 31). git diff --check passed.
@Moriafly
Moriafly merged commit 1d5baec into main Oct 30, 2026
3 checks passed
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.

1 participant