Chromium Code Reviews| Index: third_party/WebKit/Source/core/layout/ng/NGFragment.h |
| diff --git a/third_party/WebKit/Source/core/layout/ng/NGFragment.h b/third_party/WebKit/Source/core/layout/ng/NGFragment.h |
| index 3aa3bd8ba4ddd652cc79932fc6aa228fd10a915b..b0e682cac9e5292df7cd34ba330c2f67fec9aef4 100644 |
| --- a/third_party/WebKit/Source/core/layout/ng/NGFragment.h |
| +++ b/third_party/WebKit/Source/core/layout/ng/NGFragment.h |
| @@ -7,28 +7,44 @@ |
| #include "core/CoreExport.h" |
| #include "platform/LayoutUnit.h" |
| +#include "platform/heap/Handle.h" |
| +#include "wtf/Vector.h" |
| namespace blink { |
| -class CORE_EXPORT NGFragment final { |
| +class CORE_EXPORT NGFragment final : public GarbageCollected<NGFragment> { |
| public: |
| - NGFragment(LayoutUnit inlineSize, LayoutUnit blockSize); |
| - ~NGFragment() { } |
| + NGFragment(LayoutUnit inlineSize, LayoutUnit blockSize, |
| + LayoutUnit inlineOverflow, LayoutUnit blockOverflow); |
| + // Returns the border-box size. |
| LayoutUnit inlineSize() const { return m_inlineSize; } |
| LayoutUnit blockSize() const { return m_blockSize; } |
| + // Returns the size of the contents which are outside the border-box. |
|
eae
2016/08/09 16:26:01
This is a little misleading, how about:
Returns t
Gleb Lanbin
2016/08/09 16:37:46
Done.
|
| + LayoutUnit inlineOverflow() const { return m_inlineOverflow; } |
| + LayoutUnit blockOverflow() const { return m_blockOverflow; } |
| + |
| + // Returns the offset relative to the parent fragement's content-box. |
| LayoutUnit inlineOffset() const { return m_inlineOffset; } |
| LayoutUnit blockOffset() const { return m_blockOffset; } |
| + // Should only be used by the parent fragement's layout. |
| void setOffset(LayoutUnit inlineOffset, LayoutUnit blockOffset); |
| + DECLARE_TRACE(); |
| + |
| private: |
| LayoutUnit m_inlineSize; |
| LayoutUnit m_blockSize; |
| + LayoutUnit m_inlineOverflow; |
| + LayoutUnit m_blockOverflow; |
| + |
| LayoutUnit m_inlineOffset; |
| LayoutUnit m_blockOffset; |
| + |
| + HeapVector<Member<const NGFragment>> m_children; |
| }; |
| } // namespace blink |