OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) | 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) |
3 * (C) 1999 Antti Koivisto (koivisto@kde.org) | 3 * (C) 1999 Antti Koivisto (koivisto@kde.org) |
4 * (C) 2005 Allan Sandfeld Jensen (kde@carewolf.com) | 4 * (C) 2005 Allan Sandfeld Jensen (kde@carewolf.com) |
5 * (C) 2005, 2006 Samuel Weinig (sam.weinig@gmail.com) | 5 * (C) 2005, 2006 Samuel Weinig (sam.weinig@gmail.com) |
6 * Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010 Apple Inc. All rights reserv
ed. | 6 * Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010 Apple Inc. All rights reserv
ed. |
7 * Copyright (C) 2013 Adobe Systems Incorporated. All rights reserved. | 7 * Copyright (C) 2013 Adobe Systems Incorporated. All rights reserved. |
8 * | 8 * |
9 * This library is free software; you can redistribute it and/or | 9 * This library is free software; you can redistribute it and/or |
10 * modify it under the terms of the GNU Library General Public | 10 * modify it under the terms of the GNU Library General Public |
(...skipping 1796 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1807 offset += toRenderInline(o)->offsetForInFlowPositionedInline(this); | 1807 offset += toRenderInline(o)->offsetForInFlowPositionedInline(this); |
1808 | 1808 |
1809 if (offsetDependsOnPoint) | 1809 if (offsetDependsOnPoint) |
1810 *offsetDependsOnPoint |= o->isRenderFlowThread(); | 1810 *offsetDependsOnPoint |= o->isRenderFlowThread(); |
1811 | 1811 |
1812 return offset; | 1812 return offset; |
1813 } | 1813 } |
1814 | 1814 |
1815 InlineBox* RenderBox::createInlineBox() | 1815 InlineBox* RenderBox::createInlineBox() |
1816 { | 1816 { |
1817 return new (renderArena()) InlineBox(this); | 1817 return new InlineBox(this); |
1818 } | 1818 } |
1819 | 1819 |
1820 void RenderBox::dirtyLineBoxes(bool fullLayout) | 1820 void RenderBox::dirtyLineBoxes(bool fullLayout) |
1821 { | 1821 { |
1822 if (m_inlineBoxWrapper) { | 1822 if (m_inlineBoxWrapper) { |
1823 if (fullLayout) { | 1823 if (fullLayout) { |
1824 m_inlineBoxWrapper->destroy(renderArena()); | 1824 m_inlineBoxWrapper->destroy(); |
1825 m_inlineBoxWrapper = 0; | 1825 m_inlineBoxWrapper = 0; |
1826 } else | 1826 } else |
1827 m_inlineBoxWrapper->dirtyLineBoxes(); | 1827 m_inlineBoxWrapper->dirtyLineBoxes(); |
1828 } | 1828 } |
1829 } | 1829 } |
1830 | 1830 |
1831 void RenderBox::positionLineBox(InlineBox* box) | 1831 void RenderBox::positionLineBox(InlineBox* box) |
1832 { | 1832 { |
1833 if (isOutOfFlowPositioned()) { | 1833 if (isOutOfFlowPositioned()) { |
1834 // Cache the x position only if we were an INLINE type originally. | 1834 // Cache the x position only if we were an INLINE type originally. |
(...skipping 11 matching lines...) Expand all Loading... |
1846 // just below the line box (as though all the inlines that came befo
re us got | 1846 // just below the line box (as though all the inlines that came befo
re us got |
1847 // wrapped in an anonymous block, which is what would have happened
had we been | 1847 // wrapped in an anonymous block, which is what would have happened
had we been |
1848 // in flow). This value was cached in the y() of the box. | 1848 // in flow). This value was cached in the y() of the box. |
1849 layer()->setStaticBlockPosition(box->logicalTop()); | 1849 layer()->setStaticBlockPosition(box->logicalTop()); |
1850 if (style()->hasStaticBlockPosition(box->isHorizontal())) | 1850 if (style()->hasStaticBlockPosition(box->isHorizontal())) |
1851 setChildNeedsLayout(true, MarkOnlyThis); // Just go ahead and ma
rk the positioned object as needing layout, so it will update its position prope
rly. | 1851 setChildNeedsLayout(true, MarkOnlyThis); // Just go ahead and ma
rk the positioned object as needing layout, so it will update its position prope
rly. |
1852 } | 1852 } |
1853 | 1853 |
1854 // Nuke the box. | 1854 // Nuke the box. |
1855 box->remove(); | 1855 box->remove(); |
1856 box->destroy(renderArena()); | 1856 box->destroy(); |
1857 } else if (isReplaced()) { | 1857 } else if (isReplaced()) { |
1858 setLocation(roundedLayoutPoint(box->topLeft())); | 1858 setLocation(roundedLayoutPoint(box->topLeft())); |
1859 setInlineBoxWrapper(box); | 1859 setInlineBoxWrapper(box); |
1860 } | 1860 } |
1861 } | 1861 } |
1862 | 1862 |
1863 void RenderBox::deleteLineBoxWrapper() | 1863 void RenderBox::deleteLineBoxWrapper() |
1864 { | 1864 { |
1865 if (m_inlineBoxWrapper) { | 1865 if (m_inlineBoxWrapper) { |
1866 if (!documentBeingDestroyed()) | 1866 if (!documentBeingDestroyed()) |
1867 m_inlineBoxWrapper->remove(); | 1867 m_inlineBoxWrapper->remove(); |
1868 m_inlineBoxWrapper->destroy(renderArena()); | 1868 m_inlineBoxWrapper->destroy(); |
1869 m_inlineBoxWrapper = 0; | 1869 m_inlineBoxWrapper = 0; |
1870 } | 1870 } |
1871 } | 1871 } |
1872 | 1872 |
1873 LayoutRect RenderBox::clippedOverflowRectForRepaint(const RenderLayerModelObject
* repaintContainer) const | 1873 LayoutRect RenderBox::clippedOverflowRectForRepaint(const RenderLayerModelObject
* repaintContainer) const |
1874 { | 1874 { |
1875 if (style()->visibility() != VISIBLE && !enclosingLayer()->hasVisibleContent
()) | 1875 if (style()->visibility() != VISIBLE && !enclosingLayer()->hasVisibleContent
()) |
1876 return LayoutRect(); | 1876 return LayoutRect(); |
1877 | 1877 |
1878 LayoutRect r = visualOverflowRect(); | 1878 LayoutRect r = visualOverflowRect(); |
(...skipping 2791 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4670 } | 4670 } |
4671 | 4671 |
4672 if (didSplitParentAnonymousBoxes) | 4672 if (didSplitParentAnonymousBoxes) |
4673 markBoxForRelayoutAfterSplit(this); | 4673 markBoxForRelayoutAfterSplit(this); |
4674 | 4674 |
4675 ASSERT(beforeChild->parent() == this); | 4675 ASSERT(beforeChild->parent() == this); |
4676 return beforeChild; | 4676 return beforeChild; |
4677 } | 4677 } |
4678 | 4678 |
4679 } // namespace WebCore | 4679 } // namespace WebCore |
OLD | NEW |