⚠ Archived content — this site is no longer maintained.   Current WebKit documentation is at docs.webkit.org.

Changeset 179724 in webkit


Ignore:
Timestamp:
Feb 5, 2015, 4:53:37 PM (12 years ago)
Author:
Lucas Forschler
Message:

Merged r179627. rdar://problem/19432897

Location:
branches/safari-600.1.4.15-branch
Files:
10 edited
2 copied

Legend:

Unmodified
Added
Removed
  • branches/safari-600.1.4.15-branch/LayoutTests/ChangeLog

    r179722 r179724  
     12015-02-05  Lucas Forschler  <lforschler@apple.com>
     2
     3        Merge r179627
     4
     5    2015-02-03  David Hyatt  <hyatt@apple.com>
     6
     7            Tables don't repaginate properly when the pagination height changes or the pagination offset changes.
     8            https://bugs.webkit.org/show_bug.cgi?id=141207
     9            <rdar://problem/18387659>
     10
     11            Reviewed by Dean Jackson.
     12
     13            * fast/multicol/table-dynamic-movement-expected.html: Added.
     14            * fast/multicol/table-dynamic-movement.html: Added.
     15
     16    2015-02-04  Said Abou-Hallawa  <sabouhallawa@apple.com>
     17
     18            When using SVG as an image, we should load datauri images when these images are not in the image cache.
     19            https://bugs.webkit.org/show_bug.cgi?id=99677.
     20
     21            Reviewed by Darin Adler.
     22
     23            * svg/as-image/resources/image-with-nested-data-uri-images.svg: Added.
     24            This SVG has a tree of depth = 5 of nested data URI images. All the data URI images are
     25            SVG images expect the innermost one which is a png data URI image.
     26
     27            * svg/as-image/resources/image-with-nested-rects.svg: Added.
     28            This SVG produces the same drawing as image-with-nested-data-uri-images.svg does but
     29            it uses <rect> SVG elements instead.
     30
     31            * svg/as-image/svg-image-with-data-uri-background-expected.html: Added.
     32            * svg/as-image/svg-image-with-data-uri-background.html: Added.
     33            Test the data URI SVG as a css background image.
     34
     35            * svg/as-image/svg-image-with-data-uri-from-canvas-expected.html: Added.
     36            * svg/as-image/svg-image-with-data-uri-from-canvas.html: Added.
     37            Test the data URI image when it is the result of drawing an SVG image on a canvas object.
     38
     39            * svg/as-image/svg-image-with-data-uri-images-disabled-expected.html: Added.
     40            * svg/as-image/svg-image-with-data-uri-images-disabled.html: Added.
     41            Ensure the data uri images are not loaded if imagesEnabled is turned off.
     42
     43            * svg/as-image/svg-image-with-data-uri-reloading-expected.html: Added.
     44            * svg/as-image/svg-image-with-data-uri-reloading.html: Added.
     45            Test the data URI SVG when reloading the page.
     46
     47            * svg/as-image/svg-image-with-data-uri-use-data-uri-expected.svg: Added.
     48            * svg/as-image/svg-image-with-data-uri-use-data-uri.svg: Added.
     49            Test the data URI image when it is referenced from an SVG <use> tag.
     50
     51            * svg/as-image/svg-image-with-svg-data-uri-expected.html: Added.
     52            * svg/as-image/svg-image-with-svg-data-uri.html: Added.
     53            Test the data URI image when it is referenced from an HTML <img> tag.
     54
    1552015-02-05  Lucas Forschler  <lforschler@apple.com>
    256
  • branches/safari-600.1.4.15-branch/Source/WebCore/ChangeLog

    r179722 r179724  
     12015-02-05  Lucas Forschler  <lforschler@apple.com>
     2
     3        Merge r179627
     4
     5    2015-02-03  David Hyatt  <hyatt@apple.com>
     6
     7            Tables don't repaginate properly when the pagination height changes or the pagination offset changes.
     8            https://bugs.webkit.org/show_bug.cgi?id=141207
     9            <rdar://problem/18387659>
     10
     11            Reviewed by Dean Jackson.
     12
     13            Added fast/multicol/table-dynamic-movement.html
     14
     15            Change markForPaginationRelayoutIfNeeded to be called always and to check needsLayout inside it.
     16
     17            Make RenderTable override markForPaginationRelayoutIfNeeded and also dirty the sections if the table
     18            ended up getting marked for relayout.
     19
     20            Make sure rows do the right thing as well.
     21
     22            * rendering/RenderBlock.cpp:
     23            (WebCore::RenderBlock::layoutPositionedObjects):
     24            (WebCore::RenderBlock::markForPaginationRelayoutIfNeeded):
     25            * rendering/RenderBlock.h:
     26            * rendering/RenderBlockFlow.cpp:
     27            (WebCore::RenderBlockFlow::layoutBlockChild):
     28            (WebCore::RenderBlockFlow::adjustBlockChildForPagination):
     29            (WebCore::RenderBlockFlow::positionNewFloats):
     30            * rendering/RenderDeprecatedFlexibleBox.cpp:
     31            (WebCore::RenderDeprecatedFlexibleBox::layoutHorizontalBox):
     32            (WebCore::RenderDeprecatedFlexibleBox::layoutVerticalBox):
     33            * rendering/RenderTable.cpp:
     34            (WebCore::RenderTable::markForPaginationRelayoutIfNeeded):
     35            * rendering/RenderTable.h:
     36            * rendering/RenderTableRow.cpp:
     37            (WebCore::RenderTableRow::layout):
     38            * rendering/RenderTableSection.cpp:
     39            (WebCore::RenderTableSection::layout):
     40
    1412015-02-05  Lucas Forschler  <lforschler@apple.com>
    242
  • branches/safari-600.1.4.15-branch/Source/WebCore/rendering/RenderBlock.cpp

    r179071 r179724  
    14331433            r.setPreferredLogicalWidthsDirty(true, MarkOnlyThis);
    14341434       
    1435         if (!r.needsLayout())
    1436             r.markForPaginationRelayoutIfNeeded();
     1435        r.markForPaginationRelayoutIfNeeded();
    14371436       
    14381437        // We don't have to do a full layout.  We just have to update our position. Try that first. If we have shrink-to-fit width
     
    14821481void RenderBlock::markForPaginationRelayoutIfNeeded()
    14831482{
    1484     ASSERT(!needsLayout());
    1485     if (needsLayout())
     1483    if (needsLayout() || !view().layoutState()->isPaginated())
    14861484        return;
    14871485
  • branches/safari-600.1.4.15-branch/Source/WebCore/rendering/RenderBlock.h

    r169385 r179724  
    115115
    116116    void markPositionedObjectsForLayout();
    117     virtual void markForPaginationRelayoutIfNeeded() override final;
     117    virtual void markForPaginationRelayoutIfNeeded() override;
    118118   
    119119    // FIXME-BLOCKFLOW: Remove virtualizaion when all of the line layout code has been moved out of RenderBlock
  • branches/safari-600.1.4.15-branch/Source/WebCore/rendering/RenderBlockFlow.cpp

    r179071 r179724  
    706706    }
    707707
    708     if (!child.needsLayout())
    709         child.markForPaginationRelayoutIfNeeded();
     708    child.markForPaginationRelayoutIfNeeded();
    710709
    711710    bool childHadLayout = child.everHadLayout();
     
    745744            if (!child.avoidsFloats() && childBlockFlow->containsFloats())
    746745                childBlockFlow->markAllDescendantsWithFloatsForLayout();
    747             if (!child.needsLayout())
    748                 child.markForPaginationRelayoutIfNeeded();
     746            child.markForPaginationRelayoutIfNeeded();
    749747        }
    750748    }
     
    15441542            if (!child.avoidsFloats() && childRenderBlock->containsFloats())
    15451543                toRenderBlockFlow(childRenderBlock)->markAllDescendantsWithFloatsForLayout();
    1546             if (!child.needsLayout())
    1547                 child.markForPaginationRelayoutIfNeeded();
     1544            child.markForPaginationRelayoutIfNeeded();
    15481545        }
    15491546
     
    24292426        estimateRegionRangeForBoxChild(childBox);
    24302427
     2428        childBox.markForPaginationRelayoutIfNeeded();
     2429        childBox.layoutIfNeeded();
     2430       
    24312431        LayoutState* layoutState = view().layoutState();
    24322432        bool isPaginated = layoutState->isPaginated();
    2433         if (isPaginated && !childBox.needsLayout())
    2434             childBox.markForPaginationRelayoutIfNeeded();
    2435        
    2436         childBox.layoutIfNeeded();
    2437 
    24382433        if (isPaginated) {
    24392434            // If we are unsplittable and don't fit, then we need to move down.
  • branches/safari-600.1.4.15-branch/Source/WebCore/rendering/RenderDeprecatedFlexibleBox.cpp

    r170774 r179724  
    424424            child->computeAndSetBlockDirectionMargins(this);
    425425
    426             if (!child->needsLayout())
    427                 child->markForPaginationRelayoutIfNeeded();
     426            child->markForPaginationRelayoutIfNeeded();
    428427           
    429428            // Apply the child's current layout delta.
     
    500499                child->setChildNeedsLayout(MarkOnlyThis);
    501500
    502             if (!child->needsLayout())
    503                 child->markForPaginationRelayoutIfNeeded();
     501            child->markForPaginationRelayoutIfNeeded();
    504502
    505503            layoutChildIfNeededApplyingDelta(child, childLayoutDelta);
     
    745743            setHeight(height() + child->marginTop());
    746744
    747             if (!child->needsLayout())
    748                 child->markForPaginationRelayoutIfNeeded();
     745            child->markForPaginationRelayoutIfNeeded();
    749746
    750747            // Now do a layout.
  • branches/safari-600.1.4.15-branch/Source/WebCore/rendering/RenderTable.cpp

    r170774 r179724  
    15411541}
    15421542
    1543 }
     1543void RenderTable::markForPaginationRelayoutIfNeeded()
     1544{
     1545    if (!view().layoutState()->isPaginated() || (!view().layoutState()->pageLogicalHeightChanged() && (!view().layoutState()->pageLogicalHeight() || view().layoutState()->pageLogicalOffset(this, logicalTop()) == pageLogicalOffset())))
     1546        return;
     1547   
     1548    // When a table moves, we have to dirty all of the sections too.
     1549    if (!needsLayout())
     1550        setChildNeedsLayout(MarkOnlyThis);
     1551    for (auto& child : childrenOfType<RenderTableSection>(*this)) {
     1552        if (!child.needsLayout())
     1553            child.setChildNeedsLayout(MarkOnlyThis);
     1554    }
     1555}
     1556
     1557}
  • branches/safari-600.1.4.15-branch/Source/WebCore/rendering/RenderTable.h

    r166489 r179724  
    276276    LayoutUnit offsetWidthForColumn(const RenderTableCol&) const;
    277277    LayoutUnit offsetHeightForColumn(const RenderTableCol&) const;
    278 
     278   
     279    virtual void markForPaginationRelayoutIfNeeded() override final;
     280   
    279281protected:
    280282    virtual void styleDidChange(StyleDifference, const RenderStyle* oldStyle) override final;
  • branches/safari-600.1.4.15-branch/Source/WebCore/rendering/RenderTableRow.cpp

    r170774 r179724  
    169169               
    170170    for (RenderTableCell* cell = firstCell(); cell; cell = cell->nextCell()) {
    171         if (!cell->needsLayout() && paginated && view().layoutState()->pageLogicalHeight() && view().layoutState()->pageLogicalOffset(cell, cell->logicalTop()) != cell->pageLogicalOffset())
     171        if (!cell->needsLayout() && paginated && (view().layoutState()->pageLogicalHeightChanged() || (view().layoutState()->pageLogicalHeight() && view().layoutState()->pageLogicalOffset(cell, cell->logicalTop()) != cell->pageLogicalOffset())))
    172172            cell->setChildNeedsLayout(MarkOnlyThis);
    173173
  • branches/safari-600.1.4.15-branch/Source/WebCore/rendering/RenderTableSection.cpp

    r170774 r179724  
    392392
    393393    LayoutStateMaintainer statePusher(view(), *this, locationOffset(), hasTransform() || hasReflection() || style().isFlippedBlocksWritingMode());
    394 
     394    bool paginated = view().layoutState()->isPaginated();
     395   
    395396    const Vector<int>& columnPos = table()->columnPositions();
    396 
     397   
    397398    for (unsigned r = 0; r < m_grid.size(); ++r) {
    398399        Row& row = m_grid[r].row;
     
    417418        }
    418419
    419         if (RenderTableRow* rowRenderer = m_grid[r].rowRenderer)
     420        if (RenderTableRow* rowRenderer = m_grid[r].rowRenderer) {
     421            if (!rowRenderer->needsLayout() && paginated && view().layoutState()->pageLogicalHeightChanged())
     422                rowRenderer->setChildNeedsLayout(MarkOnlyThis);
     423
    420424            rowRenderer->layoutIfNeeded();
     425        }
    421426    }
    422427
Note: See TracChangeset for help on using the changeset viewer.