Make border width rounding visible to js via getComputedStyle.
CL (https://chromium-review.googlesource.com/c/525536/) moved rounding of border widths to the painting stage, hence rounding is no longer visible in js via getComputedStyle. This cl makes rounding visible again to users via getComputedStyle. This cl contains the following changes * Implemented a ZoomAdjustedPixelValueWithRounding method. - This method is the same as ZoomAdjustedPixelValue except that it rounds pixel value to 1 if original value is between 0 and 1.0. * Changed ComputedStyle for border-[top|right|bottom|left] to use ZoomAdjustedPixelValueWithRounding so that getComputedStyle will display rounded pixels for these properties (and also border-width that is a shorthand of these 4 longhand properties). * Changed a layout test. Bug: 737962 Change-Id: I0656f7ea1212fe32f866d95218995fb3de109e05 Reviewed-on: https://chromium-review.googlesource.com/560917 Commit-Queue: Jia Meng <jiameng@chromium.org> Reviewed-by:Alan Cutter <alancutter@chromium.org> Cr-Commit-Position: refs/heads/master@{#487384}
Showing
Please register or sign in to comment