Changeset 105772 in webkit
- Timestamp:
- Jan 24, 2012 12:24:11 PM (12 years ago)
- Location:
- trunk
- Files:
-
- 2 added
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/ChangeLog
r105769 r105772 1 2012-01-24 Parag Radke <nrqv63@motorola.com> 2 3 REGRESSION (r73385): Marquee with behavior="alternate" is not working 4 https://bugs.webkit.org/show_bug.cgi?id=64230 5 6 Reviewed by Simon Fraser. 7 8 Added a test case to check marquee alternate behavior with fixed width. 9 10 * fast/html/marquee-alternate-expected.txt: Added. 11 * fast/html/marquee-alternate.html: Added. 12 1 13 2012-01-24 Abhishek Arya <inferno@chromium.org> 2 14 -
trunk/Source/WebCore/ChangeLog
r105771 r105772 1 2012-01-24 Parag Radke <nrqv63@motorola.com> 2 3 REGRESSION (r73385): Marquee with behavior="alternate" is not working 4 https://bugs.webkit.org/show_bug.cgi?id=64230 5 6 Reviewed by Simon Fraser. 7 8 This patch gives correct content width for marquee, which computes 9 correct start position to scroll marquee. 10 11 Test: fast/html/marquee-alternate.html 12 13 * rendering/RenderBlock.cpp: 14 (WebCore::RenderBlock::computePreferredLogicalWidths): 15 We need(style()->marqueeBehavior() != MALTERNATE) check as we always need the marquee's 16 actual content width to compute the initial/end position in case of 'MALTERNATE'. 17 So we need to calculate the logical width in Alternate case even if fixed width is specified 18 as content has to animate between renderBox().right().x() - contentWidth() and 19 renderBox().left().x() + contentWidth(). 20 21 * rendering/RenderMarquee.cpp: 22 (WebCore::RenderMarquee::computePosition): 23 Using PreferredLogicalWidth in place of LayoutOverflow for calculating correct content width. 24 1 25 2012-01-24 Andreas Kling <awesomekling@apple.com> 2 26 -
trunk/Source/WebCore/rendering/RenderBlock.cpp
r105769 r105772 4951 4951 4952 4952 RenderStyle* styleToUse = style(); 4953 if (!isTableCell() && styleToUse->logicalWidth().isFixed() && styleToUse->logicalWidth().value() > 0 )4953 if (!isTableCell() && styleToUse->logicalWidth().isFixed() && styleToUse->logicalWidth().value() > 0 && style()->marqueeBehavior() != MALTERNATE) 4954 4954 m_minPreferredLogicalWidth = m_maxPreferredLogicalWidth = computeContentBoxLogicalWidth(styleToUse->logicalWidth().value()); 4955 4955 else { -
trunk/Source/WebCore/rendering/RenderMarquee.cpp
r95911 r105772 117 117 bool ltr = s->isLeftToRightDirection(); 118 118 int clientWidth = box->clientWidth(); 119 int contentWidth = ltr ? box->max XLayoutOverflow() : box->minXLayoutOverflow();119 int contentWidth = ltr ? box->maxPreferredLogicalWidth() : box->minPreferredLogicalWidth(); 120 120 if (ltr) 121 121 contentWidth += (box->paddingRight() - box->borderLeft());
Note: See TracChangeset
for help on using the changeset viewer.