Skip to content

Commit 1c4cbfe

Browse files
author
David Hyatt
committed
Update flexbox to Blink's tip of tree
https://bugs.webkit.org/show_bug.cgi?id=168657 Reviewed by Zalan Bujtas. Source/WebCore: Added new tests in css3/flexbox. * CMakeLists.txt: * WebCore.xcodeproj/project.pbxproj: * css/CSSComputedStyleDeclaration.cpp: (WebCore::ComputedStyleExtractor::propertyValue): * rendering/FlexibleBoxAlgorithm.cpp: Added. (WebCore::FlexItem::FlexItem): (WebCore::FlexLayoutAlgorithm::FlexLayoutAlgorithm): (WebCore::FlexLayoutAlgorithm::computeNextFlexLine): * rendering/FlexibleBoxAlgorithm.h: Added. (WebCore::FlexItem::hypotheticalMainAxisMarginBoxSize): (WebCore::FlexItem::flexBaseMarginBoxSize): (WebCore::FlexItem::flexedMarginBoxSize): (WebCore::FlexLayoutAlgorithm::isMultiline): * rendering/GridTrackSizingAlgorithm.cpp: (WebCore::GridTrackSizingAlgorithm::computeTrackBasedSize): (WebCore::GridTrackSizingAlgorithm::increaseSizesToAccommodateSpanningItems): (WebCore::GridTrackSizingAlgorithm::assumedRowsSizeForOrthogonalChild): (WebCore::GridTrackSizingAlgorithm::gridAreaBreadthForChild): (WebCore::IndefiniteSizeStrategy::recomputeUsedFlexFractionIfNeeded): * rendering/GridTrackSizingAlgorithm.h: * rendering/OrderIterator.cpp: (WebCore::OrderIterator::next): (WebCore::OrderIterator::reset): (WebCore::OrderIteratorPopulator::~OrderIteratorPopulator): (WebCore::OrderIteratorPopulator::collectChild): (WebCore::OrderIteratorPopulator::OrderIteratorPopulator): Deleted. (WebCore::OrderIteratorPopulator::removeDuplicatedOrderValues): Deleted. * rendering/OrderIterator.h: (WebCore::OrderIteratorPopulator::OrderIteratorPopulator): * rendering/RenderBlock.cpp: (WebCore::RenderBlock::updateBlockChildDirtyBitsBeforeLayout): (WebCore::RenderBlock::layoutPositionedObject): (WebCore::RenderBlock::computeBlockPreferredLogicalWidths): (WebCore::RenderBlock::computeChildPreferredLogicalWidths): (WebCore::RenderBlock::hasDefiniteLogicalHeight): (WebCore::RenderBlock::availableLogicalHeightForPercentageComputation): * rendering/RenderBlock.h: (WebCore::RenderBlock::hasPercentHeightDescendants): * rendering/RenderBlockFlow.cpp: (WebCore::RenderBlockFlow::computeInlinePreferredLogicalWidths): * rendering/RenderBox.cpp: (WebCore::RenderBox::columnFlexItemHasStretchAlignment): (WebCore::RenderBox::isStretchingColumnFlexItem): (WebCore::RenderBox::hasStretchedLogicalWidth): (WebCore::RenderBox::sizesLogicalWidthToFitContent): (WebCore::RenderBox::computeInlineDirectionMargins): (WebCore::RenderBox::cacheIntrinsicContentLogicalHeightForFlexItem): (WebCore::RenderBox::updateLogicalHeight): (WebCore::RenderBox::computeLogicalHeightWithoutLayout): (WebCore::RenderBox::skipContainingBlockForPercentHeightCalculation): (WebCore::RenderBox::shouldTreatChildAsReplacedInTableCells): (WebCore::tableCellShouldHaveZeroInitialSize): (WebCore::RenderBox::computePercentageLogicalHeight): (WebCore::RenderBox::computeReplacedLogicalHeightUsing): (WebCore::RenderBox::availableLogicalHeightUsing): (WebCore::RenderBox::percentageLogicalHeightIsResolvable): (WebCore::RenderBox::hasUnsplittableScrollingOverflow): (WebCore::flexItemHasStretchAlignment): Deleted. (WebCore::isStretchingColumnFlexItem): Deleted. (WebCore::logicalWidthIsResolvable): Deleted. (WebCore::RenderBox::hasDefiniteLogicalWidth): Deleted. (WebCore::percentageLogicalHeightIsResolvable): Deleted. (WebCore::RenderBox::percentageLogicalHeightIsResolvableFromBlock): Deleted. (WebCore::RenderBox::hasDefiniteLogicalHeight): Deleted. * rendering/RenderBox.h: (WebCore::RenderBox::isGridItem): (WebCore::RenderBox::isFlexItem): (WebCore::RenderBox::selfAlignmentNormalBehavior): * rendering/RenderBoxModelObject.cpp: (WebCore::isOutOfFlowPositionedWithImplicitHeight): (WebCore::RenderBoxModelObject::containingBlockForAutoHeightDetection): (WebCore::RenderBoxModelObject::hasAutoHeightOrContainingBlockWithAutoHeight): * rendering/RenderBoxModelObject.h: * rendering/RenderElement.cpp: (WebCore::RenderElement::removeChildInternal): * rendering/RenderFlexibleBox.cpp: (WebCore::RenderFlexibleBox::LineContext::LineContext): (WebCore::RenderFlexibleBox::RenderFlexibleBox): (WebCore::RenderFlexibleBox::computeIntrinsicLogicalWidths): (WebCore::contentAlignmentNormalBehavior): (WebCore::RenderFlexibleBox::styleDidChange): (WebCore::RenderFlexibleBox::layoutBlock): (WebCore::RenderFlexibleBox::repositionLogicalHeightDependentFlexItems): (WebCore::RenderFlexibleBox::clientLogicalBottomAfterRepositioning): (WebCore::RenderFlexibleBox::hasOrthogonalFlow): (WebCore::RenderFlexibleBox::flexBasisForChild): (WebCore::RenderFlexibleBox::crossAxisExtentForChild): (WebCore::RenderFlexibleBox::cachedChildIntrinsicContentLogicalHeight): (WebCore::RenderFlexibleBox::setCachedChildIntrinsicContentLogicalHeight): (WebCore::RenderFlexibleBox::clearCachedChildIntrinsicContentLogicalHeight): (WebCore::RenderFlexibleBox::childIntrinsicLogicalHeight): (WebCore::RenderFlexibleBox::childIntrinsicLogicalWidth): (WebCore::RenderFlexibleBox::crossAxisIntrinsicExtentForChild): (WebCore::RenderFlexibleBox::mainAxisExtentForChild): (WebCore::RenderFlexibleBox::mainAxisContentExtentForChildIncludingScrollbar): (WebCore::RenderFlexibleBox::crossAxisExtent): (WebCore::RenderFlexibleBox::mainAxisExtent): (WebCore::RenderFlexibleBox::mainAxisContentExtent): (WebCore::RenderFlexibleBox::computeMainAxisExtentForChild): (WebCore::RenderFlexibleBox::transformedWritingMode): (WebCore::RenderFlexibleBox::flowAwareMarginStartForChild): (WebCore::RenderFlexibleBox::flowAwareMarginEndForChild): (WebCore::RenderFlexibleBox::flowAwareMarginBeforeForChild): (WebCore::RenderFlexibleBox::crossAxisMarginExtentForChild): (WebCore::RenderFlexibleBox::flowAwareLocationForChild): (WebCore::RenderFlexibleBox::useChildAspectRatio): (WebCore::RenderFlexibleBox::computeMainSizeFromAspectRatioUsing): (WebCore::RenderFlexibleBox::setFlowAwareLocationForChild): (WebCore::RenderFlexibleBox::mainAxisLengthIsDefinite): (WebCore::RenderFlexibleBox::crossAxisLengthIsDefinite): (WebCore::RenderFlexibleBox::cacheChildMainSize): (WebCore::RenderFlexibleBox::clearCachedMainSizeForChild): (WebCore::RenderFlexibleBox::computeInnerFlexBaseSizeForChild): (WebCore::RenderFlexibleBox::layoutFlexItems): (WebCore::RenderFlexibleBox::autoMarginOffsetInMainAxis): (WebCore::RenderFlexibleBox::updateAutoMarginsInMainAxis): (WebCore::RenderFlexibleBox::hasAutoMarginsInCrossAxis): (WebCore::RenderFlexibleBox::availableAlignmentSpaceForChild): (WebCore::RenderFlexibleBox::updateAutoMarginsInCrossAxis): (WebCore::RenderFlexibleBox::marginBoxAscentForChild): (WebCore::RenderFlexibleBox::computeChildMarginValue): (WebCore::RenderFlexibleBox::adjustChildSizeForMinAndMax): (WebCore::RenderFlexibleBox::crossSizeForPercentageResolution): (WebCore::RenderFlexibleBox::mainSizeForPercentageResolution): (WebCore::RenderFlexibleBox::childLogicalHeightForPercentageResolution): (WebCore::RenderFlexibleBox::adjustChildSizeForAspectRatioCrossAxisMinAndMax): (WebCore::RenderFlexibleBox::constructFlexItem): (WebCore::RenderFlexibleBox::freezeViolations): (WebCore::RenderFlexibleBox::freezeInflexibleItems): (WebCore::RenderFlexibleBox::resolveFlexibleLengths): (WebCore::alignmentOffset): (WebCore::RenderFlexibleBox::setOverrideMainAxisContentSizeForChild): (WebCore::RenderFlexibleBox::staticMainAxisPositionForPositionedChild): (WebCore::RenderFlexibleBox::staticCrossAxisPositionForPositionedChild): (WebCore::RenderFlexibleBox::staticInlinePositionForPositionedChild): (WebCore::RenderFlexibleBox::staticBlockPositionForPositionedChild): (WebCore::RenderFlexibleBox::setStaticPositionForPositionedLayout): (WebCore::RenderFlexibleBox::prepareChildForPositionedLayout): (WebCore::RenderFlexibleBox::alignmentForChild): (WebCore::RenderFlexibleBox::resetAutoMarginsAndLogicalTopInCrossAxis): (WebCore::RenderFlexibleBox::needToStretchChildLogicalHeight): (WebCore::RenderFlexibleBox::childHasIntrinsicMainAxisSize): (WebCore::RenderFlexibleBox::crossAxisOverflowForChild): (WebCore::RenderFlexibleBox::layoutAndPlaceChildren): (WebCore::RenderFlexibleBox::layoutColumnReverse): (WebCore::initialAlignContentOffset): (WebCore::alignContentSpaceBetweenChildren): (WebCore::RenderFlexibleBox::alignFlexLines): (WebCore::RenderFlexibleBox::adjustAlignmentForChild): (WebCore::RenderFlexibleBox::alignChildren): (WebCore::RenderFlexibleBox::applyStretchAlignmentToChild): (WebCore::RenderFlexibleBox::flipForRightToLeftColumn): (WebCore::RenderFlexibleBox::flipForWrapReverse): (WebCore::RenderFlexibleBox::Violation::Violation): Deleted. (WebCore::RenderFlexibleBox::setCrossAxisExtent): Deleted. (WebCore::RenderFlexibleBox::flowAwareMarginAfterForChild): Deleted. (WebCore::RenderFlexibleBox::mainAxisBorderAndPaddingExtentForChild): Deleted. (WebCore::RenderFlexibleBox::mainAxisScrollbarExtentForChild): Deleted. (WebCore::RenderFlexibleBox::preferredMainAxisContentExtentForChild): Deleted. (WebCore::RenderFlexibleBox::computeNextFlexLine): Deleted. (WebCore::RenderFlexibleBox::setLogicalOverrideSize): Deleted. (WebCore::RenderFlexibleBox::numberOfInFlowPositionedChildren): Deleted. (WebCore::RenderFlexibleBox::needToStretchChild): Deleted. (WebCore::contentAlignmentNormalBehaviorFlexibleBox): Deleted. * rendering/RenderFlexibleBox.h: (WebCore::RenderFlexibleBox::orderIterator): (WebCore::RenderFlexibleBox::isFlexibleBoxImpl): * rendering/RenderFullScreen.h: * rendering/RenderGrid.cpp: (WebCore::selfAlignmentChangedToStretchInRowAxis): (WebCore::selfAlignmentChangedFromStretchInRowAxis): (WebCore::selfAlignmentChangedFromStretchInColumnAxis): (WebCore::RenderGrid::styleDidChange): (WebCore::RenderGrid::computeTrackBasedLogicalHeight): (WebCore::RenderGrid::computeTrackSizesForDefiniteSize): (WebCore::RenderGrid::gridGapForDirection): (WebCore::RenderGrid::guttersSize): (WebCore::RenderGrid::computeTrackSizesForIndefiniteSize): (WebCore::RenderGrid::computeAutoRepeatTracksCount): (WebCore::RenderGrid::trackSizesForComputedStyle): (WebCore::RenderGrid::offsetAndBreadthForPositionedChild): (WebCore::RenderGrid::populateGridPositionsForDirection): (WebCore::RenderGrid::alignSelfForChild): (WebCore::RenderGrid::justifySelfForChild): (WebCore::RenderGrid::columnAxisPositionForChild): (WebCore::RenderGrid::rowAxisPositionForChild): (WebCore::RenderGrid::columnAxisOffsetForChild): (WebCore::RenderGrid::rowAxisOffsetForChild): (WebCore::RenderGrid::needToStretchChildLogicalHeight): Deleted. * rendering/RenderGrid.h: * rendering/RenderLayer.cpp: (WebCore::RenderLayer::updateScrollbarsAfterLayout): * rendering/RenderListBox.cpp: (WebCore::RenderListBox::computeLogicalHeight): * rendering/RenderTable.cpp: (WebCore::RenderTable::layout): * rendering/RenderTableCell.cpp: (WebCore::RenderTableCell::layout): * rendering/RenderTableSection.cpp: (WebCore::shouldFlexCellChild): (WebCore::RenderTableSection::relayoutCellIfFlexed): (WebCore::RenderTableSection::layoutRows): * rendering/RenderTableSection.h: * rendering/RenderTextControl.cpp: (WebCore::RenderTextControl::computeLogicalHeight): * rendering/style/RenderStyle.cpp: (WebCore::resolvedSelfAlignment): (WebCore::RenderStyle::resolvedAlignSelf): (WebCore::RenderStyle::resolvedJustifySelf): * rendering/style/RenderStyle.h: * style/RenderTreeUpdater.cpp: (WebCore::textRendererIsNeeded): LayoutTests: * css3/flexbox/align-absolute-child-expected.txt: * css3/flexbox/align-absolute-child.html: * css3/flexbox/alignContent-applies-with-flexWrap-wrap-with-single-line-expected.txt: Added. * css3/flexbox/alignContent-applies-with-flexWrap-wrap-with-single-line.html: Added. * css3/flexbox/anonymous-block-merge-crash.html: * css3/flexbox/assert-generated-new-flexbox-expected.txt: Added. * css3/flexbox/assert-generated-new-flexbox.html: Added. * css3/flexbox/auto-height-dynamic-expected.txt: * css3/flexbox/auto-height-dynamic.html: * css3/flexbox/auto-height-with-flex-expected.html: Added. * css3/flexbox/auto-height-with-flex.html: Added. * css3/flexbox/auto-margins-expected.html: Removed. * css3/flexbox/auto-margins.html: Removed. * css3/flexbox/border-and-padding-abspos-expected.txt: Added. * css3/flexbox/border-and-padding-abspos.html: Added. * css3/flexbox/box-orient-button-expected.txt: Added. * css3/flexbox/box-orient-button.html: Added. * css3/flexbox/box-sizing-expected.txt: * css3/flexbox/box-sizing-min-max-sizes-expected.txt: * css3/flexbox/box-sizing-min-max-sizes.html: * css3/flexbox/box-sizing.html: * css3/flexbox/bug527039-expected.txt: Added. * css3/flexbox/bug527039.html: Added. * css3/flexbox/bug580586-expected.txt: Added. * css3/flexbox/bug580586.html: Added. * css3/flexbox/bug604346-expected.html: Added. * css3/flexbox/bug604346.html: Added. * css3/flexbox/bug605682-expected.txt: Added. * css3/flexbox/bug605682.html: Added. * css3/flexbox/bug633212-expected.txt: Added. * css3/flexbox/bug633212.html: Added. * css3/flexbox/bug646288-expected.txt: Added. * css3/flexbox/bug646288.html: Added. * css3/flexbox/bug669714-expected.txt: Added. * css3/flexbox/bug669714.html: Added. * css3/flexbox/canvas-dynamic-change-expected.txt: Added. * css3/flexbox/canvas-dynamic-change.html: Added. * css3/flexbox/change-flexitem-into-abspos-expected.txt: Added. * css3/flexbox/change-flexitem-into-abspos.html: Added. * css3/flexbox/child-overflow-expected.html: * css3/flexbox/child-overflow.html: * css3/flexbox/column-flex-child-with-overflow-scroll-expected.txt: Added. * css3/flexbox/column-flex-child-with-overflow-scroll.html: Added. * css3/flexbox/columns-auto-size.html: * css3/flexbox/columns-center-with-margins-and-wrap-expected.html: Added. * css3/flexbox/columns-center-with-margins-and-wrap.html: Added. * css3/flexbox/columns-center-with-margins-expected.html: Added. * css3/flexbox/columns-center-with-margins.html: Added. * css3/flexbox/columns-height-set-via-top-bottom-expected.txt: * css3/flexbox/columns-height-set-via-top-bottom.html: * css3/flexbox/content-height-with-scrollbars.html: * css3/flexbox/cross-axis-scrollbar-expected.html: * css3/flexbox/cross-axis-scrollbar.html: * css3/flexbox/css-properties-expected.txt: * css3/flexbox/css-properties.html: * css3/flexbox/csswg/flex-margin-no-collapse.html: * css3/flexbox/definite-cross-sizes-expected.txt: Added. * css3/flexbox/definite-cross-sizes.html: Added. * css3/flexbox/definite-main-size-expected.txt: Added. * css3/flexbox/definite-main-size.html: Added. * css3/flexbox/display-flexbox-set-get-expected.txt: * css3/flexbox/display-flexbox-set-get.html: * css3/flexbox/flex-algorithm-expected.txt: * css3/flexbox/flex-algorithm-min-max-expected.txt: * css3/flexbox/flex-algorithm-min-max.html: * css3/flexbox/flex-algorithm-with-margins-expected.txt: * css3/flexbox/flex-algorithm-with-margins.html: * css3/flexbox/flex-algorithm.html: * css3/flexbox/flex-align-baseline-expected.txt: * css3/flexbox/flex-align-baseline.html: * css3/flexbox/flex-align-column-expected.txt: * css3/flexbox/flex-align-column.html: * css3/flexbox/flex-align-end-expected.txt: * css3/flexbox/flex-align-end.html: * css3/flexbox/flex-align-max-expected.txt: * css3/flexbox/flex-align-max.html: * css3/flexbox/flex-align-percent-height-expected.txt: * css3/flexbox/flex-align-percent-height.html: * css3/flexbox/flex-align-stretch-expected.txt: * css3/flexbox/flex-align-stretch.html: * css3/flexbox/flex-align-vertical-writing-mode.html: * css3/flexbox/flex-align.html: * css3/flexbox/flex-column-relayout-assert-expected.txt: Added. * css3/flexbox/flex-column-relayout-assert.html: Added. * css3/flexbox/flex-factor-less-than-one-expected.txt: Added. * css3/flexbox/flex-factor-less-than-one.html: Added. * css3/flexbox/flex-flow-2-expected.txt: * css3/flexbox/flex-flow-2.html: * css3/flexbox/flex-flow-auto-margins-expected.txt: * css3/flexbox/flex-flow-auto-margins-no-available-space-assert-expected.txt: Added. * css3/flexbox/flex-flow-auto-margins-no-available-space-assert.html: Added. * css3/flexbox/flex-flow-auto-margins-no-available-space-expected.txt: * css3/flexbox/flex-flow-auto-margins-no-available-space.html: * css3/flexbox/flex-flow-auto-margins.html: * css3/flexbox/flex-flow-border-expected.txt: * css3/flexbox/flex-flow-border.html: * css3/flexbox/flex-flow-expected.txt: * css3/flexbox/flex-flow-initial-expected.txt: * css3/flexbox/flex-flow-initial.html: * css3/flexbox/flex-flow-margins-auto-size-expected.txt: * css3/flexbox/flex-flow-margins-auto-size.html: * css3/flexbox/flex-flow-margins-expected.txt: * css3/flexbox/flex-flow-margins.html: * css3/flexbox/flex-flow-orientations-expected.txt: * css3/flexbox/flex-flow-orientations.html: * css3/flexbox/flex-flow-overflow-expected.txt: * css3/flexbox/flex-flow-overflow.html: * css3/flexbox/flex-flow-padding-expected.txt: * css3/flexbox/flex-flow-padding.html: * css3/flexbox/flex-flow.html: * css3/flexbox/flex-item-child-overflow-expected.txt: * css3/flexbox/flex-item-child-overflow.html: * css3/flexbox/flex-item-contains-strict-expected.txt: Added. * css3/flexbox/flex-item-contains-strict.html: Added. * css3/flexbox/flex-item-firstLine-valid-expected.txt: * css3/flexbox/flex-item-firstLine-valid.html: * css3/flexbox/flex-justify-content-expected.txt: * css3/flexbox/flex-justify-content.html: * css3/flexbox/flex-longhand-parsing-expected.txt: * css3/flexbox/flex-longhand-parsing.html: * css3/flexbox/flex-no-flex-expected.txt: * css3/flexbox/flex-no-flex.html: * css3/flexbox/flex-one-sets-flex-basis-to-zero-px-expected.txt: Added. * css3/flexbox/flex-one-sets-flex-basis-to-zero-px.html: Added. * css3/flexbox/flex-order-expected.html: Added. * css3/flexbox/flex-order-expected.png: Removed. * css3/flexbox/flex-order-expected.txt: Removed. * css3/flexbox/flex-order.html: * css3/flexbox/flex-property-parsing-expected.txt: * css3/flexbox/flex-property-parsing.html: * css3/flexbox/flex-shorthand-flex-basis-middle-expected.txt: Added. * css3/flexbox/flex-shorthand-flex-basis-middle.html: Added. * css3/flexbox/flexbox-baseline.html: * css3/flexbox/flexbox-height-with-overflow-auto-expected.txt: Added. * css3/flexbox/flexbox-height-with-overflow-auto.html: Added. * css3/flexbox/flexbox-ignore-container-firstLetter-expected.txt: * css3/flexbox/flexbox-ignore-container-firstLetter.html: * css3/flexbox/flexbox-ignore-firstLetter-expected.txt: * css3/flexbox/flexbox-ignore-firstLetter.html: * css3/flexbox/flexbox-ignore-firstLine-expected.txt: * css3/flexbox/flexbox-ignore-firstLine.html: * css3/flexbox/flexbox-lines-must-be-stretched-by-default-expected.txt: * css3/flexbox/flexbox-lines-must-be-stretched-by-default.html: * css3/flexbox/flexbox-overflow-auto-expected.html: * css3/flexbox/flexbox-overflow-auto.html: * css3/flexbox/flexbox-with-multi-column-property-expected.html: Added. * css3/flexbox/flexbox-with-multi-column-property.html: Added. * css3/flexbox/flexbox-wordwrap-expected.txt: Added. * css3/flexbox/flexbox-wordwrap.html: Added. * css3/flexbox/flexitem-expected.txt: * css3/flexbox/flexitem-no-margin-collapsing-expected.txt: * css3/flexbox/flexitem-no-margin-collapsing.html: * css3/flexbox/flexitem-percent-height-change-expected.txt: * css3/flexbox/flexitem-percent-height-change.html: * css3/flexbox/flexitem-stretch-image-expected.txt: * css3/flexbox/flexitem-stretch-image.html: * css3/flexbox/flexitem-stretch-range.html: * css3/flexbox/flexitem.html: * css3/flexbox/floated-flexbox-expected.txt: * css3/flexbox/floated-flexbox.html: * css3/flexbox/floated-flexitem.html: * css3/flexbox/inline-flex-crash.html: * css3/flexbox/inline-flex-crash2.html: * css3/flexbox/inline-flex-expected.txt: * css3/flexbox/inline-flex.html: * css3/flexbox/inline-flexbox-ignore-firstLine-expected.txt: * css3/flexbox/inline-flexbox-ignore-firstLine.html: * css3/flexbox/inline-flexbox-wrap-vertically-width-calculation-expected.txt: Added. * css3/flexbox/inline-flexbox-wrap-vertically-width-calculation.html: Added. * css3/flexbox/insert-text-crash.html: * css3/flexbox/intrinsic-min-width-applies-with-fixed-width-expected.txt: * css3/flexbox/intrinsic-min-width-applies-with-fixed-width.html: * css3/flexbox/intrinsic-width-orthogonal-writing-mode-expected.txt: Added. * css3/flexbox/intrinsic-width-orthogonal-writing-mode.html: Added. * css3/flexbox/large-flex-shrink-assert-expected.txt: Added. * css3/flexbox/large-flex-shrink-assert.html: Added. * css3/flexbox/line-wrapping.html: * css3/flexbox/mainAxisExtent-crash-expected.txt: Added. * css3/flexbox/mainAxisExtent-crash.html: Added. * css3/flexbox/max-width-violation-expected.txt: Added. * css3/flexbox/max-width-violation.html: Added. * css3/flexbox/min-size-auto-expected.txt: * css3/flexbox/min-size-auto.html: * css3/flexbox/minimum-size-image-expected.txt: Added. * css3/flexbox/minimum-size-image.html: Added. * css3/flexbox/multiline-align-content-expected.txt: * css3/flexbox/multiline-align-content-horizontal-column-expected.txt: * css3/flexbox/multiline-align-content-horizontal-column.html: * css3/flexbox/multiline-align-content.html: * css3/flexbox/multiline-align-self-expected.txt: * css3/flexbox/multiline-align-self.html: * css3/flexbox/multiline-column-auto-expected.txt: * css3/flexbox/multiline-column-auto.html: * css3/flexbox/multiline-column-overflow-expected.html: Added. * css3/flexbox/multiline-column-overflow.html: Added. * css3/flexbox/multiline-expected.txt: * css3/flexbox/multiline-justify-content-expected.txt: * css3/flexbox/multiline-justify-content.html: * css3/flexbox/multiline-min-max-expected.txt: Added. * css3/flexbox/multiline-min-max.html: Added. * css3/flexbox/multiline-min-preferred-width-expected.txt: * css3/flexbox/multiline-min-preferred-width.html: * css3/flexbox/multiline-reverse-wrap-baseline.html: * css3/flexbox/multiline-reverse-wrap-overflow-expected.txt: * css3/flexbox/multiline-reverse-wrap-overflow.html: * css3/flexbox/multiline-shrink-to-fit-expected.html: * css3/flexbox/multiline-shrink-to-fit.html: * css3/flexbox/multiline.html: * css3/flexbox/negative-flex-rounding-assert.html: * css3/flexbox/negative-margins-assert.html: * css3/flexbox/negative-overflow-expected.txt: * css3/flexbox/negative-overflow.html: * css3/flexbox/nested-flexbox-min-size-auto-expected.txt: Added. * css3/flexbox/nested-flexbox-min-size-auto.html: Added. * css3/flexbox/nested-orthogonal-flexbox-relayout-expected.html: Added. * css3/flexbox/nested-orthogonal-flexbox-relayout.html: Added. * css3/flexbox/nested-stretch-expected.txt: * css3/flexbox/nested-stretch.html: * css3/flexbox/order-painting.html: * css3/flexbox/orthogonal-flex-directions-expected.txt: * css3/flexbox/orthogonal-flex-directions.html: * css3/flexbox/orthogonal-writing-modes-and-intrinsic-sizing-expected.txt: Added. * css3/flexbox/orthogonal-writing-modes-and-intrinsic-sizing.html: Added. * css3/flexbox/overflow-and-padding-expected.txt: Added. * css3/flexbox/overflow-and-padding.html: Added. * css3/flexbox/overflow-auto-dynamic-changes-abspos-expected.html: Added. * css3/flexbox/overflow-auto-dynamic-changes-abspos.html: Added. * css3/flexbox/overflow-auto-dynamic-changes-expected.html: Added. * css3/flexbox/overflow-auto-dynamic-changes.html: Added. * css3/flexbox/overflow-auto-resizes-correctly-expected.txt: Added. * css3/flexbox/overflow-auto-resizes-correctly.html: Added. * css3/flexbox/overflow-keep-scrollpos-expected.txt: * css3/flexbox/overflow-keep-scrollpos.html: * css3/flexbox/percent-height-children-of-alignSelf-stretch-flex-item-expected.txt: Added. * css3/flexbox/percent-height-children-of-alignSelf-stretch-flex-item.html: Added. * css3/flexbox/percent-margins-expected.txt: * css3/flexbox/percent-margins.html: * css3/flexbox/percentage-height-in-abspos-expected.html: Added. * css3/flexbox/percentage-height-in-abspos.html: Added. * css3/flexbox/percentage-height-replaced-element-expected.txt: Added. * css3/flexbox/percentage-height-replaced-element.html: Added. * css3/flexbox/percentage-heights-expected.txt: * css3/flexbox/percentage-heights.html: * css3/flexbox/percentage-max-width-cross-axis-expected.txt: Added. * css3/flexbox/percentage-max-width-cross-axis.html: Added. * css3/flexbox/percentage-sizes-expected.txt: * css3/flexbox/percentage-sizes-quirks-expected.txt: * css3/flexbox/percentage-sizes-quirks.html: * css3/flexbox/percentage-sizes.html: * css3/flexbox/percentage-width-in-abspos-expected.html: Added. * css3/flexbox/percentage-width-in-abspos.html: Added. * css3/flexbox/perpendicular-writing-modes-inside-flex-item-expected.txt: * css3/flexbox/perpendicular-writing-modes-inside-flex-item.html: * css3/flexbox/position-absolute-child-expected.txt: * css3/flexbox/position-absolute-child.html: * css3/flexbox/position-absolute-children-expected.txt: * css3/flexbox/position-absolute-children.html: * css3/flexbox/preferred-widths-expected.txt: * css3/flexbox/preferred-widths-orthogonal.html: * css3/flexbox/preferred-widths.html: * css3/flexbox/relayout-align-items-expected.txt: * css3/flexbox/relayout-align-items.html: * css3/flexbox/relayout-image-load-expected.txt: * css3/flexbox/relayout-image-load.html: * css3/flexbox/relpos-with-percentage-top-expected.txt: Added. * css3/flexbox/relpos-with-percentage-top.html: Added. * css3/flexbox/relpos-with-scrollable-with-abspos-crash-expected.txt: Added. * css3/flexbox/relpos-with-scrollable-with-abspos-crash.html: Added. * css3/flexbox/resize-min-content-flexbox-expected.txt: Added. * css3/flexbox/resize-min-content-flexbox.html: Added. * css3/flexbox/resources/box-orient-button.js: Added. (setFlexDirection): (gebi): (test): * css3/flexbox/scrollbars-auto-expected.html: Added. * css3/flexbox/scrollbars-auto.html: Added. * css3/flexbox/scrollbars-expected.html: Added. * css3/flexbox/scrollbars.html: Added. * css3/flexbox/shrinking-column-flexbox-expected.txt: Added. * css3/flexbox/shrinking-column-flexbox.html: Added. * css3/flexbox/stretch-after-sibling-size-change-expected.txt: * css3/flexbox/stretch-after-sibling-size-change.html: * css3/flexbox/stretch-input-in-column-expected.html: * css3/flexbox/stretch-simplified-layout-expected.txt: * css3/flexbox/stretch-simplified-layout.html: * css3/flexbox/stretch-table-child-expected.txt: Added. * css3/flexbox/stretch-table-child.html: Added. * css3/flexbox/stretched-child-shrink-on-relayout-expected.txt: Added. * css3/flexbox/stretched-child-shrink-on-relayout.html: Added. * css3/flexbox/stretching-orthogonal-flows-expected.html: Added. * css3/flexbox/stretching-orthogonal-flows.html: Added. * css3/flexbox/style-change-expected.txt: * css3/flexbox/style-change.html: * css3/flexbox/text-overflow-on-flexbox-expected.html: Added. * css3/flexbox/text-overflow-on-flexbox.html: Added. * css3/flexbox/true-centering-expected.txt: * css3/flexbox/true-centering.html: * css3/flexbox/undefined-min-width-expected.txt: Added. * css3/flexbox/undefined-min-width.html: Added. * css3/flexbox/vertical-align-do-not-effect-flex-items-expected.html: Added. * css3/flexbox/vertical-align-do-not-effect-flex-items.html: Added. * css3/flexbox/vertical-flexbox-percentage-ignored-expected.html: Added. * css3/flexbox/vertical-flexbox-percentage-ignored.html: Added. * css3/flexbox/whitespace-in-flexitem-expected.html: Added. * css3/flexbox/whitespace-in-flexitem.html: Added. * css3/flexbox/width-change-and-relayout-children-expected.txt: * css3/flexbox/width-change-and-relayout-children.html: * css3/flexbox/wrapping-column-dynamic-changes-expected.txt: Added. * css3/flexbox/wrapping-column-dynamic-changes.html: Added. * css3/flexbox/writing-modes-expected.txt: * css3/flexbox/writing-modes.html: * css3/flexbox/z-index.html: * resources/check-layout-th.js: Added. (checkSubtreeExpectedValues): (checkAttribute): (assert_tolerance): (checkExpectedValues): (window.checkLayout): Canonical link: https://commits.webkit.org/185959@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@213149 268f45cc-cd09-0410-ab3c-d52691b4dbfc
1 parent 0810762 commit 1c4cbfe

351 files changed

Lines changed: 11750 additions & 8341 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

LayoutTests/ChangeLog

Lines changed: 326 additions & 0 deletions
Large diffs are not rendered by default.

LayoutTests/TestExpectations

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1194,5 +1194,8 @@ svg/custom/filter-source-alpha.svg [ Skip ]
11941194
# Test landed disabled in r26904; never enabled
11951195
svg/custom/font-face-fallback.svg [ Skip ]
11961196

1197+
# Test disabled until we can fix layout of orthogonal writing mode roots
1198+
fast/table/colspanMinWidth-vertical.html [ Skip ]
1199+
11971200
### END OF -disabled tests
11981201
########################################
Lines changed: 18 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,18 @@
1-
PASS beforePosition[key] is afterPosition[key]
2-
PASS beforePosition[key] is afterPosition[key]
3-
PASS beforePosition[key] is afterPosition[key]
4-
PASS beforePosition[key] is afterPosition[key]
5-
PASS beforePosition[key] is afterPosition[key]
6-
PASS beforePosition[key] is afterPosition[key]
7-
PASS beforePosition[key] is afterPosition[key]
8-
PASS
9-
PASS
10-
PASS
11-
PASS
12-
PASS
13-
PASS
14-
PASS
15-
PASS
16-
PASS
1+
2+
PASS position of top
3+
PASS position of right
4+
PASS position of bottom
5+
PASS position of left
6+
PASS position of width
7+
PASS position of height
8+
PASS position of toJSON
9+
PASS .flexbox 1
10+
PASS .flexbox 2
11+
PASS .flexbox 3
12+
PASS .flexbox 4
13+
PASS .flexbox 5
14+
PASS .flexbox 6
15+
PASS .flexbox 7
16+
PASS .flexbox 8
17+
PASS .flexbox 9
18+

LayoutTests/css3/flexbox/align-absolute-child.html

Lines changed: 25 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,7 @@
1212
margin: 10px;
1313
}
1414
.flexbox > * {
15-
-webkit-flex: none;
16-
-moz-flex: none;
15+
flex: none;
1716
}
1817
.relative {
1918
position: relative;
@@ -60,79 +59,81 @@
6059
}
6160
</style>
6261

63-
<script src="../../resources/js-test-pre.js"></script>
64-
<script src="../../resources/check-layout.js"></script>
62+
<script src="../../resources/testharness.js"></script>
63+
<script src="../../resources/testharnessreport.js"></script>
64+
<script src="../../resources/check-layout-th.js"></script>
6565

6666
<body onload="checkLayout('.flexbox')">
67+
<div id=log></div>
6768

6869
<div class='flexbox relative align-items-center'>
6970
<div id='placed-absolute' class='absolute' data-offset-x=20 data-offset-y=20></div>
7071
</div>
7172

7273
<div class='flexbox relative align-items-center'>
7374
<div data-offset-x=0 data-offset-y=40></div>
74-
<div class='absolute' data-offset-x=20 data-offset-y=0></div>
75+
<div class='absolute' data-offset-x=0 data-offset-y=40></div>
7576
<div data-offset-x=20 data-offset-y=40></div>
7677
<div class="absolute" style="top: 5px; left: 5px" data-offset-x=5 data-offset-y=5></div>
7778
</div>
7879

7980
<div class="relative">
8081
<div class='flexbox align-items-center'>
8182
<div data-offset-x=10 data-offset-y=40></div>
82-
<div class='absolute' data-offset-x=30 data-offset-y=0></div>
83+
<div class='absolute' data-offset-x=10 data-offset-y=40></div>
8384
<div data-offset-x=30 data-offset-y=40></div>
8485
<div class="absolute" style="top: 5px; left: 5px" data-offset-x=5 data-offset-y=5></div>
8586
</div>
8687
</div>
8788

8889
<div class='flexbox relative column rtl'>
8990
<div data-offset-x=80 data-offset-y=0></div>
90-
<div class='absolute' data-offset-x=80 data-offset-y=20></div>
91+
<div class='absolute' data-offset-x=80 data-offset-y=0></div>
9192
<div data-offset-x=80 data-offset-y=20></div>
9293
<div class="absolute" style="top: 5px; left: 5px" data-offset-x=5 data-offset-y=5></div>
9394
</div>
9495

9596
<div class="relative">
9697
<div class='flexbox wrap-reverse'>
9798
<div style="width:90px" data-offset-x=10 data-offset-y=80></div>
98-
<div class="absolute" data-offset-x=100 data-offset-y=100></div>
99+
<div class="absolute" data-offset-x=10 data-offset-y=80></div>
99100
<div data-offset-x=10 data-offset-y=30></div>
100-
<div class="absolute" data-offset-x=30 data-offset-y=50></div>
101+
<div class="absolute" data-offset-x=10 data-offset-y=80></div>
101102
<div data-offset-x=30 data-offset-y=30></div>
102-
<div class="absolute" data-offset-x=50 data-offset-y=50></div>
103+
<div class="absolute" data-offset-x=10 data-offset-y=80></div>
103104
<div class="absolute" style="top: 5px; left: 5px" data-offset-x=5 data-offset-y=5></div>
104105
</div>
105106
</div>
106107

107108
<div class='flexbox relative'>
108109
<div style="margin: auto;" data-offset-x=40 data-offset-y=40></div>
109-
<div class="absolute" style="margin: auto;" data-offset-x=100 data-offset-y=0></div>
110-
<div class="absolute" style="margin: auto;" data-offset-x=100 data-offset-y=0></div>
110+
<div class="absolute" style="margin: auto;" data-offset-x=0 data-offset-y=0></div>
111+
<div class="absolute" style="margin: auto;" data-offset-x=0 data-offset-y=0></div>
111112
<div class="absolute" style="margin: auto; top: 5px; left: 5px" data-offset-x=5 data-offset-y=5></div>
112113
</div>
113114

114115
<div class='flexbox align-items-stretch relative'>
115116
<div style="height: auto" data-offset-x=0 data-offset-y=0 data-expected-height=100></div>
116-
<div class="absolute" style="height: auto" data-offset-x=20 data-offset-y=0 data-expected-height=0></div>
117+
<div class="absolute" style="height: auto" data-offset-x=0 data-offset-y=0 data-expected-height=0></div>
117118
<div class="absolute" style="height: auto; top: 5px; left: 5px" data-offset-x=5 data-offset-y=5 data-expected-height=0></div>
118119
</div>
119120

120121
<div class="flexbox wrap relative">
121122
<div style="width: 100px;" data-offset-x=0 data-offset-y=0></div>
122-
<div class="absolute" data-offset-x=100 data-offset-y=0></div>
123+
<div class="absolute" data-offset-x=0 data-offset-y=0></div>
123124
<div style="width: 50px;" data-offset-x=0 data-offset-y=50></div>
124-
<div class="absolute" data-offset-x=50 data-offset-y=50></div>
125+
<div class="absolute" data-offset-x=0 data-offset-y=0></div>
125126
<div style="width: 50px;" data-offset-x=50 data-offset-y=50></div>
126-
<div class="absolute" data-offset-x=100 data-offset-y=50></div>
127+
<div class="absolute" data-offset-x=0 data-offset-y=0></div>
127128
</div>
128129

129130
<div class="flexbox wrap relative align-items-flex-end">
130131
<div style="width: 100px;" data-offset-x=0 data-offset-y=30></div>
131-
<div class="absolute" data-offset-x=100 data-offset-y=0></div>
132+
<div class="absolute" data-offset-x=0 data-offset-y=80></div>
132133
<div style="width: 50px;" data-offset-x=0 data-offset-y=80></div>
133-
<div class="absolute" data-offset-x=50 data-offset-y=50></div>
134+
<div class="absolute" data-offset-x=0 data-offset-y=80></div>
134135
<div style="width: 50px;" data-offset-x=50 data-offset-y=80></div>
135-
<div class="absolute" data-offset-x=100 data-offset-y=50></div>
136+
<div class="absolute" data-offset-x=0 data-offset-y=80></div>
136137
</div>
137138

138139

@@ -143,8 +144,11 @@
143144
var afterPosition = absolute.getBoundingClientRect();
144145

145146
// Positioned element should not change position when the height of it's parent flexbox is changed.
146-
for (key in beforePosition)
147-
shouldBe('beforePosition[key]', 'afterPosition[key]');
147+
for (key in beforePosition) {
148+
test(function() {
149+
assert_equals(beforePosition[key], afterPosition[key]);
150+
}, 'position of ' + key);
151+
}
148152
</script>
149153
</body>
150154
</html>
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
2+
PASS .default, .verticalWriting 1
3+
PASS .default, .verticalWriting 2
4+
PASS .default, .verticalWriting 3
5+
PASS .default, .verticalWriting 4
6+
PASS .default, .verticalWriting 5
7+
PASS .default, .verticalWriting 6
8+
PASS .default, .verticalWriting 7
9+
PASS .default, .verticalWriting 8
10+
PASS .default, .verticalWriting 9
11+
PASS .default, .verticalWriting 10
12+
PASS .default, .verticalWriting 11
13+
PASS .default, .verticalWriting 12
14+
Test for BUG=324178: Chrome incorrectly honors "align-content" in "flex-wrap: wrap" flex containers that only have a single line
15+
16+
This text should be at the top of its container
17+
This text should be at the top of its container
18+
This text should be at the top of its container
19+
This text should be at the top of its container
20+
This text should be at the top of its container
21+
This text should be at the top of its container
22+
This text should be at the left of its container
23+
This text should be at the left of its container
24+
This text should be at the left of its container
25+
This text should be at the left of its container
26+
This text should be at the left of its container
27+
This text should be at the left of its container
Lines changed: 68 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,68 @@
1+
<!doctype html>
2+
<html>
3+
<head>
4+
<style>
5+
.default {
6+
display: flex;
7+
flex-wrap: wrap;
8+
position: relative;
9+
height: 75px;
10+
border: 1px solid red;
11+
margin: 5px;
12+
}
13+
14+
.verticalWriting {
15+
display: flex;
16+
flex-wrap: wrap;
17+
position: relative;
18+
width: 75px;
19+
border: 1px solid red;
20+
margin: 5px;
21+
writing-mode: vertical-lr;
22+
}
23+
</style>
24+
<script src="../../resources/testharness.js"></script>
25+
<script src="../../resources/testharnessreport.js"></script>
26+
<script src="../../resources/check-layout-th.js"></script>
27+
</head>
28+
<body onload="checkLayout('.default, .verticalWriting'); ">
29+
<div id=log></div>
30+
<p>Test for BUG=324178: Chrome incorrectly honors "align-content" in "flex-wrap: wrap" flex containers that only have a single line</p>
31+
<div class="default" style="align-content: flex-start">
32+
<div data-offset-y="0">This text should be at the top of its container</div>
33+
</div>
34+
<div class="default" style="align-content: flex-end">
35+
<div data-offset-y="0">This text should be at the top of its container</div>
36+
</div>
37+
<div class="default" style="align-content: center">
38+
<div data-offset-y="0">This text should be at the top of its container</div>
39+
</div>
40+
<div class="default" style="align-content: space-between">
41+
<div data-offset-y="0">This text should be at the top of its container</div>
42+
</div>
43+
<div class="default" style="align-content: space-around">
44+
<div data-offset-y="0">This text should be at the top of its container</div>
45+
</div>
46+
<div class="default" style="align-content: stretch">
47+
<div data-offset-y="0">This text should be at the top of its container</div>
48+
</div>
49+
<div class="verticalWriting" style="align-content: flex-start">
50+
<div data-offset-x="0">This text should be at the left of its container</div>
51+
</div>
52+
<div class="verticalWriting" style="align-content: flex-end">
53+
<div data-offset-x="0">This text should be at the left of its container</div>
54+
</div>
55+
<div class="verticalWriting" style="align-content: center">
56+
<div data-offset-x="0">This text should be at the left of its container</div>
57+
</div>
58+
<div class="verticalWriting" style="align-content: space-between">
59+
<div data-offset-x="0">This text should be at the left of its container</div>
60+
</div>
61+
<div class="verticalWriting" style="align-content: space-around">
62+
<div data-offset-x="0">This text should be at the left of its container</div>
63+
</div>
64+
<div class="verticalWriting" style="align-content: stretch">
65+
<div data-offset-x="0">This text should be at the left of its container</div>
66+
</div>
67+
</body>
68+
</html>

LayoutTests/css3/flexbox/anonymous-block-merge-crash.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<div style="display:-webkit-flex; display:-moz-flex;"><div id="inner"></div>If this page doesn't crash then this test passes.</div>
1+
<div style="display:flex;"><div id="inner"></div>If this page doesn't crash then this test passes.</div>
22
<script>
33
if (window.testRunner)
44
testRunner.dumpAsText()
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
Bug 91003: ASSERT(genChild->isListMarker() || genChild->style()->styleType() == FIRST_LETTER) triggered on flex-box content
2+
3+
This test has passed if it doesn't crash or ASSERT.
4+
5+
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
<!DOCTYPE html>
2+
<html>
3+
<style>
4+
div:after {
5+
content: 'Generated content wrapped in a flex-box.';
6+
display: -webkit-flex;
7+
}
8+
</style>
9+
<script>
10+
if (window.testRunner)
11+
testRunner.dumpAsText();
12+
</script>
13+
<p>Bug <a href="https://bugs.webkit.org/show_bug.cgi?id=91003">91003</a>: ASSERT(genChild->isListMarker() || genChild->style()->styleType() == FIRST_LETTER) triggered on flex-box content</p>
14+
<p>This test has passed if it doesn't crash or ASSERT.</p>
15+
<div></div>
16+
</html>
Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,4 @@
1-
PASS
2-
PASS
1+
2+
PASS .flexbox 1
3+
PASS .flexbox 2
4+

0 commit comments

Comments
 (0)