forked from jamesblasco/modal_bottom_sheet
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
add Sheet.addPostLayoutCallback static method
Expanding [Sheet] using [SheetController] might not always work, e.g. you are trying to animate the sheet and expand controller at the same time (see: jamesblasco#412) You can use [addPostLayoutCallback] in order to defer your call to the moment [RenderSheetViewport] has finished [RenderSheetViewport.performLayout] Additionally you can provide [timeout] after which this callback should be called anyway incase [RenderSheetViewport.performLayout] doesn't start. Usually (this has not been super benchmarked!) layout starts under 50ms, putting 100ms to be on the safe side - YMMV
- Loading branch information
Łukasz Wiśniewski
authored and
Łukasz Wiśniewski
committed
Jun 28, 2024
1 parent
e44458d
commit 25f393f
Showing
1 changed file
with
55 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters