[webkit-reviews] review requested: [Bug 6141] DOMCSSPrimitiveValue is always returning values in pixels when using getComputedStyle: : [Attachment 7887] Patch

bugzilla-request-daemon at opendarwin.org bugzilla-request-daemon at opendarwin.org
Fri Apr 21 16:19:14 PDT 2006


Beth Dakin <bdakin at apple.com> has asked  for review:
Bug 6141: DOMCSSPrimitiveValue is always returning values in pixels when using
getComputedStyle:
http://bugzilla.opendarwin.org/show_bug.cgi?id=6141

Attachment 7887: Patch
http://bugzilla.opendarwin.org/attachment.cgi?id=7887&action=edit

------- Additional Comments from Beth Dakin <bdakin at apple.com>
Here is a patch that fixes the bug. I talked through this design with Hyatt.
Since we use getFloatValue() internally a lot, I created another version that
still just returns m_value.num since that is what the internal callers expect
and since passing in the type was clunky and unnecessary. It is also worth
noting that the given test case does not contain the exact value we return. The
test case expects that we render floating point pixels, but we round to
integers. This causes the expected calculation to be off from the actual
calculation. (It also means that our results, while accurate, do not match
Firefox exactly.) I will upload a more accurate test in a minute.



More information about the webkit-reviews mailing list