Changeset 14067 in webkit
- Timestamp:
- Apr 25, 2006 3:35:33 PM (18 years ago)
- Location:
- trunk
- Files:
-
- 4 added
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/ChangeLog
r14058 r14067 1 2006-04-25 Beth Dakin <bdakin@apple.com> 2 3 Reviewed by Maciej. 4 5 Layout test for <rdar://problem/4518632> getComputedStyle returns 6 'auto' for dimensions like 'margin-left' 7 8 * fast/css/marginComputedStyle-expected.checksum: Added. 9 * fast/css/marginComputedStyle-expected.png: Added. 10 * fast/css/marginComputedStyle-expected.txt: Added. 11 * fast/css/marginComputedStyle.html: Added. 12 1 13 2006-04-26 Mitz Pettel <opendarwin.org@mitzpettel.com> 2 14 -
trunk/WebCore/ChangeLog
r14058 r14067 1 2006-04-25 Beth Dakin <bdakin@apple.com> 2 3 Reviewed by Maciej. 4 5 Fix for <rdar://problem/4518632> getComputedStyle returns 'auto' 6 for dimensions like 'margin-left' 7 8 * css/CSSComputedStyleDeclaration.cpp: 9 (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue): For 10 margin and padding, to match Firefox we now go to the renderer to 11 get the property value instead of calling valueForLength() on the 12 style attribute. valueForLength() will return the string 'auto' if 13 that was what was specified in the CSS, or a percentage if it was 14 specified as a percent. But to match Firefox, we always want to 15 return a pixel value for margin and padding. 16 1 17 2006-04-26 Mitz Pettel <opendarwin.org@mitzpettel.com> 2 18 -
trunk/WebCore/css/CSSComputedStyleDeclaration.cpp
r13959 r14067 787 787 return 0; 788 788 case CSS_PROP_MARGIN_TOP: 789 return valueForLength(style->marginTop());789 return new CSSPrimitiveValue(renderer->marginTop(), CSSPrimitiveValue::CSS_PX); 790 790 case CSS_PROP_MARGIN_RIGHT: 791 return valueForLength(style->marginRight());791 return new CSSPrimitiveValue(renderer->marginRight(), CSSPrimitiveValue::CSS_PX); 792 792 case CSS_PROP_MARGIN_BOTTOM: 793 return valueForLength(style->marginBottom());793 return new CSSPrimitiveValue(renderer->marginBottom(), CSSPrimitiveValue::CSS_PX); 794 794 case CSS_PROP_MARGIN_LEFT: 795 return valueForLength(style->marginLeft());795 return new CSSPrimitiveValue(renderer->marginLeft(), CSSPrimitiveValue::CSS_PX); 796 796 case CSS_PROP__WEBKIT_MARQUEE: 797 797 // FIXME: unimplemented … … 894 894 return 0; 895 895 case CSS_PROP_PADDING_TOP: 896 return valueForLength(style->paddingTop());896 return new CSSPrimitiveValue(renderer->paddingTop(), CSSPrimitiveValue::CSS_PX); 897 897 case CSS_PROP_PADDING_RIGHT: 898 return valueForLength(style->paddingRight());898 return new CSSPrimitiveValue(renderer->paddingRight(), CSSPrimitiveValue::CSS_PX); 899 899 case CSS_PROP_PADDING_BOTTOM: 900 return valueForLength(style->paddingBottom());900 return new CSSPrimitiveValue(renderer->paddingBottom(), CSSPrimitiveValue::CSS_PX); 901 901 case CSS_PROP_PADDING_LEFT: 902 return valueForLength(style->paddingLeft());902 return new CSSPrimitiveValue(renderer->paddingLeft(), CSSPrimitiveValue::CSS_PX); 903 903 case CSS_PROP_PAGE: 904 904 // FIXME: unimplemented
Note: See TracChangeset
for help on using the changeset viewer.