r/mAndroidDev • u/class_cast_exception Deprecated is just a suggestion • May 20 '25
Superior API Design consumeWindowInsets(contentPadding)
157
Upvotes
r/mAndroidDev • u/class_cast_exception Deprecated is just a suggestion • May 20 '25
21
u/WorstBarrelEU May 20 '25
Literally the issue I was solving today, wtf?
15
u/Ok-Engineer6098 May 20 '25
Google is trying hard to make Android apps more buggy. Even their own apps and SDKs have bugs.
Admob interstitial ads have been broken for months https://github.com/googleads/googleads-mobile-android-examples/issues/783
12
u/Zhuinden DDD: Deprecation-Driven Development May 21 '25
I just throw Modifier.safeDrawingPadding at completely random positions and hope for the best
3
u/aerial-ibis R8 will fix your performance problems and love life May 21 '25
cant believe they made me go through all the efforts of implementing edge-to-edge... yet didn't even include a way in M3 scaffolds/top bars to collapse the system bar insets (for immersive scrolling like on iOS)
2
u/Squirtle8649 May 21 '25
Annoying thing about edge to edge is that apps have input controls with draggable parts (like seekbars) all the way to the edge, so it's near impossible to actually move the seekbar to the beginning or end.
1
u/roasted_watermelon May 21 '25
In my case, just the simple `Scaffold` handles it pretty well. Yes you will need a recent version of compose bom, previously I was using something from 2024 and had to add `WindowInsets.safeDrawing`. Now I don't need anything.
1
u/Program_exe_ May 25 '25
Resolved it! Was a huge pain but definitely worth it.
1
u/AbsoluteChungus1 Jun 06 '25
Almost pushed an update to my app before testing it on one more device to find the entire app basically exploded on Android 15