james04/12/2022, 11:24 PM
is enabled, the ModalBottomSheet re-animates into the screen from the bottom during the keyboard close process, despite the fact the modal was already on screen in the Expanded state. Further, while creating a video to show this bug I discovered that the layout does not obey the Animation Scale from Developer Settings (which was introduced in 1.2.0-alpha05), whereas other Compose components do in fact obey those settings. Wanted to check if anyone else knows about this or if it has already been filed on the issue tracker, before I file an issue myself.
jossiwolf04/13/2022, 10:26 AM
james04/13/2022, 10:50 AM
class source, where I can actually stop the “bug” from happening altogether by disabling a snap call. From 0:00 - 0:30 in this video I just click the “close keyboard” button and run through the breakpoints without changing anything, and we see the bug occur. At 0:40 you see me change the targetOffset from 784.0f to 0.0f, and this is done just as a trick to make the code inside the function
effectively do nothing.. if you dig into that function it just does a dragBy() for <targetOffset minus absoluteOffset>, and at this stage absoluteOffset is 0.0f, so it’s calling dragBy(0.0f) At 0:54 I change targetOffset back to its original value to ensure an exception is not thrown by the anchors map getValue() call. You can see in the second instance where click the “close keyboard” button but I have effectively “disabled” the
call, and we see that the bug does not occur