Revert "CrOS Shelf: Change icon centering strategy"
This reverts commit 0a9cd867. Reason for revert: ShelfViewTest.IconCenteringTest is failing on bots. https://test-results.appspot.com/dashboards/flakiness_dashboard.html#testType=ash_unittests&tests=ShelfViewTest.IconCenteringTest https://ci.chromium.org/p/chromium/builders/ci/linux-chromeos-rel/21645 https://ci.chromium.org/p/chromium/builders/ci/linux-chromeos-rel/21646 Original change's description: > CrOS Shelf: Change icon centering strategy > > The main change here is that icons are first centered on the whole > screen, then, when space becomes tighter, they are centered over the > available area on the shelf. > > A few changes to make this work properly: > > * Fix an issue in |GetDimensionOfCenteredShelfItems| which was taking > into account all items, even the ones within overflow, making the > calculations incorrect. > * Another issue was that the code calculating ideal bounds would > assume control buttons (app list, back, overflow) were the same size > as app buttons (56) while they're actually a little smaller (40). > Giving control buttons their "real" size in the layout code allows > for the removal of some overrides at each button class level. > * Split out a small chunk from |CalculateIdealBounds| which is getting > too long. More of that to come in future changes. > * Make the special spacing between the app list button and the first > app icon also there on the other side for more symmetry. > > Also add some extensive test coverage. > > Bug: 891080, 933291 > Change-Id: If4bb69aa6e182cd29c02d467039b5d839d09f493 > Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1512299 > Commit-Queue: Manu Cornet <manucornet@chromium.org> > Reviewed-by: Xiyuan Xia <xiyuan@chromium.org> > Cr-Commit-Position: refs/heads/master@{#642245} TBR=xiyuan@chromium.org,manucornet@chromium.org Change-Id: I4ad5f95b4c6b2db13e05a6e280e987f25981392b No-Presubmit: true No-Tree-Checks: true No-Try: true Bug: 891080, 933291 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1531922Reviewed-by:Kunihiko Sakamoto <ksakamoto@chromium.org> Commit-Queue: Kunihiko Sakamoto <ksakamoto@chromium.org> Cr-Commit-Position: refs/heads/master@{#642409}
Showing
This diff is collapsed.
Please register or sign in to comment