• Charlene Yan's avatar
    [Tab Groups] Add tabs to the closest available position within a group. · 835cf2d2
    Charlene Yan authored
    Previously, tabs would always get inserted to the end of the tab group.
    This changes it such that if the tab is currently to the left of the
    group, it will be inserted at the front of the tab group respecting the
    relative order of the selected tabs. If the tabs are to the right of
    the group, it will be inserted to the end of the tab group as before
    (no behavior change).
    
    This change also allows tabs in a group to be restored to the location
    saved at closing time, or the closest location if the group has moved.
    
    Bug: 1030779, 1038362
    Change-Id: Id26cdfa2df769bc738d780e48277e603acef42ae
    Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1977849
    Commit-Queue: Charlene Yan <cyan@chromium.org>
    Reviewed-by: default avatarPeter Boström <pbos@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#728337}
    835cf2d2
tab_strip_model.cc 73.3 KB