[Webkit-unassigned] [Bug 70898] Range sliders and spin buttons don't work with multi-columns

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Thu Nov 3 16:46:07 PDT 2011


https://bugs.webkit.org/show_bug.cgi?id=70898





--- Comment #9 from mitz at webkit.org  2011-11-03 16:46:07 PST ---
(From update of attachment 112842)
View in context: https://bugs.webkit.org/attachment.cgi?id=112842&action=review

It might be better to make this change in two steps, first moving the functions up to RenderBoxModelObject, and then actually fixing the bug.

> Source/WebCore/rendering/RenderBoxModelObject.cpp:2616
> +        ColumnInfo* colInfo = block->columnInfo();
> +        LayoutPoint point(roundedLayoutPoint(transformState.mappedPoint()));
> +        point -= containerOffset;
> +        size_t colCount = block->columnCount(colInfo);
> +        for (size_t i = 0; i < colCount; i++) {
> +            LayoutRect colRect = block->columnRectAt(colInfo, i);
> +            if (colRect.contains(point)) {
> +                if (i) {
> +                    LayoutRect colRect0 = block->columnRectAt(colInfo, 0);
> +                    if (block->isHorizontalWritingMode())
> +                        containerOffset.expand(colRect.location().x() - colRect0.location().x(), -colInfo->columnHeight() * i);
> +                    else
> +                        containerOffset.expand(-colInfo->desiredColumnWidth() * i, colRect.location().y() - colRect0.location().y());
> +                }
> +                break;
> +            }
> +        }

This logic belongs in a new function in RenderBlock, where hitTestColumns() can share it. In fact, you should factor out the version in hitTestColumns(), because that version correctly accounts for flipped blocks writing modes and for block-axis column progression.

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.



More information about the webkit-unassigned mailing list