OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2013 Google Inc. All rights reserved. | 2 * Copyright (C) 2013 Google Inc. All rights reserved. |
3 * | 3 * |
4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
5 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
6 * met: | 6 * met: |
7 * | 7 * |
8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
10 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
(...skipping 15 matching lines...) Expand all Loading... |
26 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT | 26 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT |
27 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE | 27 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE |
28 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | 28 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
29 */ | 29 */ |
30 | 30 |
31 #include "config.h" | 31 #include "config.h" |
32 #include "core/rendering/RenderBlockFlow.h" | 32 #include "core/rendering/RenderBlockFlow.h" |
33 | 33 |
34 #include "core/accessibility/AXObjectCache.h" | 34 #include "core/accessibility/AXObjectCache.h" |
35 #include "core/frame/FrameView.h" | 35 #include "core/frame/FrameView.h" |
| 36 #include "core/frame/LocalFrame.h" |
| 37 #include "core/frame/Settings.h" |
36 #include "core/rendering/HitTestLocation.h" | 38 #include "core/rendering/HitTestLocation.h" |
37 #include "core/rendering/RenderFlowThread.h" | 39 #include "core/rendering/RenderFlowThread.h" |
38 #include "core/rendering/RenderLayer.h" | 40 #include "core/rendering/RenderLayer.h" |
39 #include "core/rendering/RenderMultiColumnFlowThread.h" | 41 #include "core/rendering/RenderMultiColumnFlowThread.h" |
40 #include "core/rendering/RenderPagedFlowThread.h" | 42 #include "core/rendering/RenderPagedFlowThread.h" |
41 #include "core/rendering/RenderText.h" | 43 #include "core/rendering/RenderText.h" |
42 #include "core/rendering/RenderView.h" | 44 #include "core/rendering/RenderView.h" |
43 #include "core/rendering/TextAutosizer.h" | 45 #include "core/rendering/TextAutosizer.h" |
44 #include "core/rendering/line/LineWidth.h" | 46 #include "core/rendering/line/LineWidth.h" |
45 #include "core/rendering/svg/SVGTextRunRenderingContext.h" | 47 #include "core/rendering/svg/SVGTextRunRenderingContext.h" |
(...skipping 1716 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1762 RenderBlock::computeOverflow(oldClientAfterEdge, recomputeFloats); | 1764 RenderBlock::computeOverflow(oldClientAfterEdge, recomputeFloats); |
1763 if (!hasColumns() && (recomputeFloats || createsBlockFormattingContext() ||
hasSelfPaintingLayer())) | 1765 if (!hasColumns() && (recomputeFloats || createsBlockFormattingContext() ||
hasSelfPaintingLayer())) |
1764 addOverflowFromFloats(); | 1766 addOverflowFromFloats(); |
1765 } | 1767 } |
1766 | 1768 |
1767 RootInlineBox* RenderBlockFlow::createAndAppendRootInlineBox() | 1769 RootInlineBox* RenderBlockFlow::createAndAppendRootInlineBox() |
1768 { | 1770 { |
1769 RootInlineBox* rootBox = createRootInlineBox(); | 1771 RootInlineBox* rootBox = createRootInlineBox(); |
1770 m_lineBoxes.appendLineBox(rootBox); | 1772 m_lineBoxes.appendLineBox(rootBox); |
1771 | 1773 |
1772 if (UNLIKELY(AXObjectCache::accessibilityEnabled()) && m_lineBoxes.firstLine
Box() == rootBox) { | |
1773 if (AXObjectCache* cache = document().existingAXObjectCache()) | |
1774 cache->recomputeIsIgnored(this); | |
1775 } | |
1776 | |
1777 return rootBox; | 1774 return rootBox; |
1778 } | 1775 } |
1779 | 1776 |
1780 void RenderBlockFlow::deleteLineBoxTree() | 1777 void RenderBlockFlow::deleteLineBoxTree() |
1781 { | 1778 { |
1782 if (containsFloats()) | 1779 if (containsFloats()) |
1783 m_floatingObjects->clearLineBoxTreePointers(); | 1780 m_floatingObjects->clearLineBoxTreePointers(); |
1784 | 1781 |
1785 m_lineBoxes.deleteLineBoxTree(); | 1782 m_lineBoxes.deleteLineBoxTree(); |
1786 | |
1787 if (AXObjectCache* cache = document().existingAXObjectCache()) | |
1788 cache->recomputeIsIgnored(this); | |
1789 } | 1783 } |
1790 | 1784 |
1791 void RenderBlockFlow::markAllDescendantsWithFloatsForLayout(RenderBox* floatToRe
move, bool inLayout) | 1785 void RenderBlockFlow::markAllDescendantsWithFloatsForLayout(RenderBox* floatToRe
move, bool inLayout) |
1792 { | 1786 { |
1793 if (!everHadLayout() && !containsFloats()) | 1787 if (!everHadLayout() && !containsFloats()) |
1794 return; | 1788 return; |
1795 | 1789 |
1796 if (m_descendantsWithFloatsMarkedForLayout && !floatToRemove) | 1790 if (m_descendantsWithFloatsMarkedForLayout && !floatToRemove) |
1797 return; | 1791 return; |
1798 m_descendantsWithFloatsMarkedForLayout |= !floatToRemove; | 1792 m_descendantsWithFloatsMarkedForLayout |= !floatToRemove; |
(...skipping 1112 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2911 RenderBlockFlow::RenderBlockFlowRareData& RenderBlockFlow::ensureRareData() | 2905 RenderBlockFlow::RenderBlockFlowRareData& RenderBlockFlow::ensureRareData() |
2912 { | 2906 { |
2913 if (m_rareData) | 2907 if (m_rareData) |
2914 return *m_rareData; | 2908 return *m_rareData; |
2915 | 2909 |
2916 m_rareData = adoptPtrWillBeNoop(new RenderBlockFlowRareData(this)); | 2910 m_rareData = adoptPtrWillBeNoop(new RenderBlockFlowRareData(this)); |
2917 return *m_rareData; | 2911 return *m_rareData; |
2918 } | 2912 } |
2919 | 2913 |
2920 } // namespace blink | 2914 } // namespace blink |
OLD | NEW |