• Jinsuk Kim's avatar
    Android: Dynamic half/full state height for BottomSheet · 03b0df53
    Jinsuk Kim authored
    This CL makes half/full state height of BottomSheet dynamic so that
    the sheet can have both half/full state and keep the content
    wrapped. Gesture navigation shows how it can be used as an example. By
    overriding BottomSheetContent.getCustomized{Half,Full}Ratio:
    
     - The sheet expands to the half state with content wrapped. The height
       is maxed out at the half the container height.
    
     - If slided up, the content moves to the full state, the content
       still wrapped. The height is maxed out at the full container height,
       and the content becomes scrollable if necessary.
    
    Bug: 993051
    Change-Id: I7e000716ee6b544b541d385e34cae026d64798d4
    Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1781123
    Commit-Queue: Jinsuk Kim <jinsukkim@chromium.org>
    Reviewed-by: default avatarMatthew Jones <mdjones@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#696716}
    03b0df53
dimens.xml 35.7 KB