diff options
Diffstat (limited to 'chromium/third_party/blink/renderer/core/layout/ng/inline/ng_fragment_items_builder.h')
-rw-r--r-- | chromium/third_party/blink/renderer/core/layout/ng/inline/ng_fragment_items_builder.h | 19 |
1 files changed, 14 insertions, 5 deletions
diff --git a/chromium/third_party/blink/renderer/core/layout/ng/inline/ng_fragment_items_builder.h b/chromium/third_party/blink/renderer/core/layout/ng/inline/ng_fragment_items_builder.h index eef2fc77231..84be85e4132 100644 --- a/chromium/third_party/blink/renderer/core/layout/ng/inline/ng_fragment_items_builder.h +++ b/chromium/third_party/blink/renderer/core/layout/ng/inline/ng_fragment_items_builder.h @@ -59,10 +59,21 @@ class CORE_EXPORT NGFragmentItemsBuilder { void AddListMarker(const NGPhysicalBoxFragment& marker_fragment, const LogicalOffset& offset); + // Find |LogicalOffset| of the first |NGFragmentItem| for |LayoutObject|. + base::Optional<LogicalOffset> LogicalOffsetFor(const LayoutObject&) const; + + // Converts the |NGFragmentItem| vector to the physical coordinate space and + // returns the result. This should only be used for determining the inline + // containing block geometry for OOF-positioned nodes. + // + // Once this method has been called, new items cannot be added. + const Vector<std::unique_ptr<NGFragmentItem>>& + Items(WritingMode, TextDirection, const PhysicalSize& outer_size); + // Build a |NGFragmentItems|. The builder cannot build twice because data set // to this builder may be cleared. - void ToFragmentItems(WritingMode writing_mode, - TextDirection direction, + void ToFragmentItems(WritingMode, + TextDirection, const PhysicalSize& outer_size, void* data); @@ -73,8 +84,6 @@ class CORE_EXPORT NGFragmentItemsBuilder { TextDirection direction, const PhysicalSize& outer_size); - void AssociateNextForSameLayoutObject(); - Vector<std::unique_ptr<NGFragmentItem>> items_; Vector<LogicalOffset> offsets_; String text_content_; @@ -84,10 +93,10 @@ class CORE_EXPORT NGFragmentItemsBuilder { ChildList current_line_; bool has_floating_descendants_for_paint_ = false; + bool is_converted_to_physical_ = false; #if DCHECK_IS_ON() const NGPhysicalLineBoxFragment* current_line_fragment_ = nullptr; - bool is_converted_to_physical_ = false; #endif friend class NGFragmentItems; |