Open papjul opened 8 months ago
Regarding the window inset changes, I tested it on Android 15 both with the target and compileSdk set to 34 and 35. In both cases, the insets were handled identically to previous Android versions. I didn't notice any new issues here.[1]
The only issue is that the color of the system bars cannot be customized anymore:
There is an extensive article about insets handling which mentions this in 7. Background protect system bars only when necessary:
However, there are some cases where you wish to preserve the background color of the system bars, but the APIs to set the status and navigation bar colors are deprecated. We are planning to release an AndroidX library to support this use case.
The suggested workaround is to "place a composable or view behind the system bar". Although I'm still undecided if I like that approach.
[1]In landscape mode with three-button navigation some system bar insets are applied twice (by the root layout and by compose), but this is a different issue and not related to changing the SDK.
So it will be possible once the AndroidX library update is released?
I don't think SDK 35 is ready yet. It was just released on AOSP and it's not even there yet on Pixels. Let's just wait a bit more ;)
With targetSDK = 35 the shade which is applied to the status bar when scrolling in the home fragment can no longer be applied on Android 15.
As far as I know, the AndroidX library which should support this hasn't been release yet. As mentioned in my previous comment, the workaround is to use a composable or view to draw a background behind the system bars. I could submit a PR for this.
Ah yes, you're right. I would prefer the library over a drawing. Can you open a separate issue with relevant links about the upstream known issue?
I couldn't find any related issue in the Google issue tracker or any other details about it. It's only mentioned in the official Android blog post about insets handling on Android 15.
I would prefer the library over a drawing.
Agreed. After thinking about it again, I realized that we don't need the statusBarColor
attribute. As we only want to set a white or black shade we can actually use enforceStatusBarContrast
as a replacement in Window.setSystemBarStyle. That attribute is also deprecated in SDK 35, but unlike the color attribute it's still usable.
That should be a viable workaround until the promised library is released.
It does look actually better than the current state! Thank you
Behavior changes when compileSdk = 35
https://developer.android.com/about/versions/15/behavior-changes-all
Network errors when using a satellite connection should be ignored using https://developer.android.com/reference/android/telephony/ServiceState?#isUsingNonTerrestrialNetwork%28%29I can't remember a reason to do thisBehavior changes when targetSdk = 35
https://developer.android.com/about/versions/15/behavior-changes-15
Service.onTimeout(int, int)
BOOT_COMPLETED
broadcast receivers launching foreground services:dataSync
services can no longer be launched => check if we are impactedUSE_NEW_ISO_LOCALE_CODES
. Language codes for Hebrew, Yiddish, and Indonesian are no longer converted to their obsolete forms (Hebrew: iw, Yiddish: ji, and Indonesian: in).New SDK 35 features
https://developer.android.com/about/versions/15/features?hl=en
Deprecated in API level 35
To be completed
Last year schedule (SDK 34)
Current schedule (SDK 35)