• Toni Barzic's avatar
    Edge case where shelf background is not reshown for hotseat transition · 16013993
    Toni Barzic authored
    Fixes an edge case where opaque shelf background doesn't get reshown
    after it's hidden for transition from home screen.
    The opaque background is hidden when transition from kShown hotseat
    state starts, and reshown once it ends. In both cases ShelfView checks
    the original hotseat state to determine whether the opaque background
    state should be updated.
    
    This does not work if the original hotseat transition is interrupted by
    another hotseat state change (to kShown state, as only transitions
    from/to shown state are animated) - in this case hosteat transition
    animator stops observing implicit animations before it updates the
    animating backgrounf transform, so it doesn't send the end notification
    for initial transition. Once the second animation finishes, the shelf
    widget delegate will only see the end notification for the second
    transition, and given the hotseat state is not kShown, it will not
    update the opaque background visibility.
    
    (If the user exits tablet mode before going to home screen again, they
    will see completely transparent shelf).
    
    BUG=1044751
    
    Change-Id: I07e15126215c908831ad24b4aeb525eb2ef66513
    Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2032008Reviewed-by: default avatarManu Cornet <manucornet@chromium.org>
    Commit-Queue: Toni Baržić <tbarzic@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#737216}
    16013993
shelf_widget.cc 28.1 KB