Improve list of display zoom values
This patch changes the logic the list of zoom values are computed for a given display. The new logic has 2 scenarios for listing the zoom values for a given display. 1) Displays with device scale factors assigned to them, will now have zoom values ranging from the inverse of device scale factor to device scale factor. If there are still slider ticks avaiable we use them to add zoom levels beyond the device scale factor. Doing this allows the user to go to the native resolution of the display and on the other hand it also allows them to zoom in if required. We no longer allow the user to go to a zoom below the native resolution of the display as this is a very unlikely scenario and introduces artifacts. This also gives finer control to the user in setting the zoom level. How this effects a pixelbook for example? On pixelbook we used to have a zoom range of 50% to 175%. Due to the wide range, the consecutive values were too far apart and users wanted zoom values that were mostly in the range of 70% to 100%. With the new change, the range will go from 50% to 130%. 2) Displays with no device scale factors assigned to them will use a static list of initialized zoom values. Bug: 845634 Change-Id: I69a761856dab4e5b37b85420f6f6dfebdb2dead5 Component: Display zoom, display util Reviewed-on: https://chromium-review.googlesource.com/1069561 Commit-Queue: Malay Keshav <malaykeshav@chromium.org> Reviewed-by:Ahmed Fakhry <afakhry@chromium.org> Cr-Commit-Position: refs/heads/master@{#563050}
Showing
Please register or sign in to comment