commit | c17f37304d2bd6dbb18a06b283ce78f5796d8f14 | [log] [tgz] |
---|---|---|
author | Calder Kitagawa <ckitagawa@chromium.org> | Tue Jun 24 13:32:48 2025 |
committer | Chromium LUCI CQ <chromium-scoped@luci-project-accounts.iam.gserviceaccount.com> | Tue Jun 24 13:32:48 2025 |
tree | 719258fc8cfd6609acfe90cee47a3e323db7e575 | |
parent | 9cb07acfc1df60668d169d89278a3df66500d601 [diff] |
[Tab Model] Rework TabModelImpl#moveTab Move tab was highly confusing. It was implemented in such a way that moving a tab to a higher index required adding a +1 offset to account for the fact the rest of the list would shift. This is not how list reorder operations typically work and as a result lots of hacks to workaround the issue existed in code. Just do what is more intuitive instead and move the tab directly to the index. New logic: Tab Index < Destination Index - all the tabs before or at the destination index will shuffle one index down to make room. Tab Index > Destination Index - all tabs at or after the destination index will shuffle one index up to make room. Fixed: 425902847 Change-Id: Iaf83324bfde1ea35232c1faa2df29b0dfb25d3c7 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6652242 Reviewed-by: Sky Malice <skym@chromium.org> Commit-Queue: Calder Kitagawa <ckitagawa@chromium.org> Cr-Commit-Position: refs/heads/main@{#1477877}
Chromium is an open-source browser project that aims to build a safer, faster, and more stable way for all users to experience the web.
The project's web site is https://www.chromium.org.
To check out the source code locally, don't use git clone
! Instead, follow the instructions on how to get the code.
Documentation in the source is rooted in docs/README.md.
Learn how to Get Around the Chromium Source Code Directory Structure.
For historical reasons, there are some small top level directories. Now the guidance is that new top level directories are for product (e.g. Chrome, Android WebView, Ash). Even if these products have multiple executables, the code should be in subdirectories of the product.
If you found a bug, please file it at https://crbug.com/new.