| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2000 Lars Knoll (knoll@kde.org) | 2 * Copyright (C) 2000 Lars Knoll (knoll@kde.org) |
| 3 * Copyright (C) 2003, 2004, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All r
ight reserved. | 3 * Copyright (C) 2003, 2004, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All r
ight reserved. |
| 4 * Copyright (C) 2010 Google Inc. All rights reserved. | 4 * Copyright (C) 2010 Google Inc. All rights reserved. |
| 5 * Copyright (C) 2014 Adobe Systems Incorporated. All rights reserved. | 5 * Copyright (C) 2014 Adobe Systems Incorporated. All rights reserved. |
| 6 * | 6 * |
| 7 * This library is free software; you can redistribute it and/or | 7 * This library is free software; you can redistribute it and/or |
| 8 * modify it under the terms of the GNU Library General Public | 8 * modify it under the terms of the GNU Library General Public |
| 9 * License as published by the Free Software Foundation; either | 9 * License as published by the Free Software Foundation; either |
| 10 * version 2 of the License, or (at your option) any later version. | 10 * version 2 of the License, or (at your option) any later version. |
| (...skipping 27 matching lines...) Expand all Loading... |
| 38 LineLayoutState(bool fullLayout, LayoutUnit& paintInvalidationLogicalTop, La
youtUnit& paintInvalidationLogicalBottom, LayoutFlowThread* flowThread) | 38 LineLayoutState(bool fullLayout, LayoutUnit& paintInvalidationLogicalTop, La
youtUnit& paintInvalidationLogicalBottom, LayoutFlowThread* flowThread) |
| 39 : m_lastFloat(nullptr) | 39 : m_lastFloat(nullptr) |
| 40 , m_endLine(nullptr) | 40 , m_endLine(nullptr) |
| 41 , m_floatIndex(0) | 41 , m_floatIndex(0) |
| 42 , m_endLineLogicalTop(0) | 42 , m_endLineLogicalTop(0) |
| 43 , m_endLineMatched(false) | 43 , m_endLineMatched(false) |
| 44 , m_hasInlineChild(false) | 44 , m_hasInlineChild(false) |
| 45 , m_isFullLayout(fullLayout) | 45 , m_isFullLayout(fullLayout) |
| 46 , m_paintInvalidationLogicalTop(paintInvalidationLogicalTop) | 46 , m_paintInvalidationLogicalTop(paintInvalidationLogicalTop) |
| 47 , m_paintInvalidationLogicalBottom(paintInvalidationLogicalBottom) | 47 , m_paintInvalidationLogicalBottom(paintInvalidationLogicalBottom) |
| 48 , m_adjustedLogicalLineTop(0) | |
| 49 , m_usesPaintInvalidationBounds(false) | 48 , m_usesPaintInvalidationBounds(false) |
| 50 , m_flowThread(flowThread) | 49 , m_flowThread(flowThread) |
| 51 { } | 50 { } |
| 52 | 51 |
| 53 void markForFullLayout() { m_isFullLayout = true; } | 52 void markForFullLayout() { m_isFullLayout = true; } |
| 54 bool isFullLayout() const { return m_isFullLayout; } | 53 bool isFullLayout() const { return m_isFullLayout; } |
| 55 | 54 |
| 56 bool usesPaintInvalidationBounds() const { return m_usesPaintInvalidationBou
nds; } | 55 bool usesPaintInvalidationBounds() const { return m_usesPaintInvalidationBou
nds; } |
| 57 | 56 |
| 58 void setPaintInvalidationRange(LayoutUnit logicalHeight) | 57 void setPaintInvalidationRange(LayoutUnit logicalHeight) |
| 59 { | 58 { |
| 60 m_usesPaintInvalidationBounds = true; | 59 m_usesPaintInvalidationBounds = true; |
| 61 m_paintInvalidationLogicalTop = m_paintInvalidationLogicalBottom = logic
alHeight; | 60 m_paintInvalidationLogicalTop = m_paintInvalidationLogicalBottom = logic
alHeight; |
| 62 } | 61 } |
| 63 | 62 |
| 64 void updatePaintInvalidationRangeFromBox(RootInlineBox* box, LayoutUnit pagi
nationDelta = 0) | 63 void updatePaintInvalidationRangeFromBox(RootInlineBox* box, LayoutUnit pagi
nationDelta = LayoutUnit()) |
| 65 { | 64 { |
| 66 m_usesPaintInvalidationBounds = true; | 65 m_usesPaintInvalidationBounds = true; |
| 67 m_paintInvalidationLogicalTop = std::min(m_paintInvalidationLogicalTop,
box->logicalTopVisualOverflow() + std::min<LayoutUnit>(paginationDelta, 0)); | 66 m_paintInvalidationLogicalTop = std::min(m_paintInvalidationLogicalTop,
box->logicalTopVisualOverflow() + paginationDelta.clampPositiveToZero()); |
| 68 m_paintInvalidationLogicalBottom = std::max(m_paintInvalidationLogicalBo
ttom, box->logicalBottomVisualOverflow() + std::max<LayoutUnit>(paginationDelta,
0)); | 67 m_paintInvalidationLogicalBottom = std::max(m_paintInvalidationLogicalBo
ttom, box->logicalBottomVisualOverflow() + paginationDelta.clampNegativeToZero()
); |
| 69 } | 68 } |
| 70 | 69 |
| 71 bool endLineMatched() const { return m_endLineMatched; } | 70 bool endLineMatched() const { return m_endLineMatched; } |
| 72 void setEndLineMatched(bool endLineMatched) { m_endLineMatched = endLineMatc
hed; } | 71 void setEndLineMatched(bool endLineMatched) { m_endLineMatched = endLineMatc
hed; } |
| 73 | 72 |
| 74 bool hasInlineChild() const { return m_hasInlineChild; } | 73 bool hasInlineChild() const { return m_hasInlineChild; } |
| 75 void setHasInlineChild(bool hasInlineChild) { m_hasInlineChild = hasInlineCh
ild; } | 74 void setHasInlineChild(bool hasInlineChild) { m_hasInlineChild = hasInlineCh
ild; } |
| 76 | 75 |
| 77 | 76 |
| 78 LineInfo& lineInfo() { return m_lineInfo; } | 77 LineInfo& lineInfo() { return m_lineInfo; } |
| (...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 118 LayoutUnit m_adjustedLogicalLineTop; | 117 LayoutUnit m_adjustedLogicalLineTop; |
| 119 | 118 |
| 120 bool m_usesPaintInvalidationBounds; | 119 bool m_usesPaintInvalidationBounds; |
| 121 | 120 |
| 122 LayoutFlowThread* m_flowThread; | 121 LayoutFlowThread* m_flowThread; |
| 123 }; | 122 }; |
| 124 | 123 |
| 125 } // namespace blink | 124 } // namespace blink |
| 126 | 125 |
| 127 #endif // LineLayoutState_h | 126 #endif // LineLayoutState_h |
| OLD | NEW |