Refactor usage of GetTabEndcapWidth()/GetCornerRadius().
The pre-refresh use of "endcap" isn't quite as clear in refresh, where tabs appear to start suddenly at a point that turns out to be halfway through the "endcap". Instead, restrict usage of GetTabEndcapWidth() (now renamed for parallelism with GetTabEndcapWidthForPainting()) to pre-refresh. In refresh, use GetCornerRadius(), whose relationship to the tab's appearance is more clear. This adds a new GetContentsInsets() static method as well, which allows decoupling the concept of the endcap width/corner radius from "how far into the tab bounds does content start", which is what a number of callers really care about. Removing dependencies on GetMinimumInactiveTabWidth() will be useful for allowing narrower tabs. Bug: none Change-Id: Ic749c4b3f1b2c3611db0fa4966d62513367aec51 Reviewed-on: https://chromium-review.googlesource.com/1121818Reviewed-by:Allen Bauer <kylixrd@chromium.org> Commit-Queue: Peter Kasting <pkasting@chromium.org> Cr-Commit-Position: refs/heads/master@{#572024}
Showing
Please register or sign in to comment