There is a regression in Compose 1.9.0-alpha01: ap...
# compose
g
There is a regression in Compose 1.9.0-alpha01: applying
ViewCompat.setOnApplyWindowInsetsListener
on a
ComposeView
has no effect (the lambda is never called). I've filed an issue. This is a blocker for our project to update Compose to 1.9.0-alpha01, so hopefully this will get a higher priority 🙂
a
Thanks for the bug! I can give a bit of insight into what might be happening here -
ViewCompat.setOnApplyWindowInsetsListener
only allows setting one listener per
View
- and in 1.9 there’s a new one that is being added internal to the Compose mechanisms. So what’s likely happening is that you set your listener first, and then a new internal Compose one is overwriting it. A workaround would be setting the listener on a
View
you control completely.
g
I see, now it makes sense, thanks!