Skip to content

Fix map screen system bar insets#2280

Open
AvikMakwana wants to merge 1 commit into
owntracks:masterfrom
AvikMakwana:fix/2170-map-system-insets
Open

Fix map screen system bar insets#2280
AvikMakwana wants to merge 1 commit into
owntracks:masterfrom
AvikMakwana:fix/2170-map-system-insets

Conversation

@AvikMakwana

Copy link
Copy Markdown

Fixes #2170

Summary

  • Apply system bar insets to the drawer app bar so toolbar navigation and action icons stay inside the safe drawing area in landscape.
  • Recalculate map-screen margins and padding from original/base values to avoid accumulated padding after rotation or repeated inset dispatch.
  • Apply safe-area padding to map controls including the layers FAB, my-location FAB, OSM compass, and OSM attribution.
  • Pass viewport padding into both map implementations:
    • OSS/osmdroid adjusts MapView padding plus compass and attribution offsets.
    • GMS applies GoogleMap.setPadding(...).
  • Make map-related bottom sheets inset-aware and scrollable so Monitoring Mode and Map Layers content stays visible above gesture and three-button navigation bars.
  • Preserve existing XML/activity/map-fragment architecture.

Verification

Commands run:

  • ./gradlew.bat app:ktfmtCheck
  • ./gradlew.bat app:testOssDebugUnitTest
  • ./gradlew.bat app:lintOssDebug
  • ./gradlew.bat app:assembleOssDebug
  • ./gradlew.bat app:assembleGmsDebug
  • git diff --check

Manual verification on Motorola Edge 50 Fusion, ossDebug:

  • PASS: Portrait + gesture navigation
  • PASS: Portrait + three-button navigation
  • PASS: Landscape + gesture navigation
  • PASS: Landscape + three-button navigation
  • PASS: Toolbar icons safe from side navigation bar
  • PASS: Layers FAB safe from system bars
  • PASS: My-location FAB safe from system bars
  • PASS: OSM attribution visible
  • PASS: Monitoring Mode sheet visible/scrollable
  • PASS: Map Layers sheet visible/scrollable
  • PASS: Rotation does not accumulate padding
  • PASS: Navigation drawer behavior unchanged
  • PASS: Map pan/zoom behavior unchanged

Notes:

  • OSS behavior was manually verified on device.
  • GMS was compile-checked with app:assembleGmsDebug.

@AvikMakwana AvikMakwana marked this pull request as ready for review July 6, 2026 06:11
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.

Map elements and "current contact" bottom sheet clip under app bar and navigation bar

1 participant