| Index: third_party/WebKit/Source/core/editing/iterators/TextIteratorTextNodeHandler.h
|
| diff --git a/third_party/WebKit/Source/core/editing/iterators/TextIteratorTextNodeHandler.h b/third_party/WebKit/Source/core/editing/iterators/TextIteratorTextNodeHandler.h
|
| index 48d15960197d1099e7449fd7e9019c226bf81f71..90eacccc550748118c6d1bfdae10bcdf163d0a7e 100644
|
| --- a/third_party/WebKit/Source/core/editing/iterators/TextIteratorTextNodeHandler.h
|
| +++ b/third_party/WebKit/Source/core/editing/iterators/TextIteratorTextNodeHandler.h
|
| @@ -7,12 +7,15 @@
|
|
|
| #include "core/dom/Text.h"
|
| #include "core/editing/iterators/TextIteratorBehavior.h"
|
| +#include "core/layout/ng/inline/ng_offset_mapping_builder.h"
|
| +#include "core/layout/ng/inline/ng_offset_mapping_result.h"
|
| #include "platform/heap/Handle.h"
|
| #include "platform/wtf/Vector.h"
|
|
|
| namespace blink {
|
|
|
| class InlineTextBox;
|
| +class LayoutNGBlockFlow;
|
| class LayoutText;
|
| class LayoutTextFragment;
|
| class TextIteratorTextState;
|
| @@ -56,6 +59,8 @@ class TextIteratorTextNodeHandler final
|
| size_t RestoreCollapsedTrailingSpace(InlineTextBox* next_text_box,
|
| size_t subrun_end);
|
|
|
| + void HandleTextNodeInNGBlockFlow(const LayoutNGBlockFlow&);
|
| +
|
| // Used when the visibility of the style should not affect text gathering.
|
| bool IgnoresStyleVisibility() const {
|
| return behavior_.IgnoresStyleVisibility();
|
| @@ -76,6 +81,15 @@ class TextIteratorTextNodeHandler final
|
| int offset_ = 0;
|
| int end_offset_ = 0;
|
|
|
| + // The current containing block if the text node is laid out with LayoutNG.
|
| + const LayoutNGBlockFlow* ng_block_flow_ = nullptr;
|
| +
|
| + // The DOM to text content offset mapping in the containing block if the text
|
| + // node is laid out with LayoutNG.
|
| + // TODO(xiaochengh): The offset mapping should be managed in its own cached,
|
| + // not directly by its clients.
|
| + NGOffsetMappingResult mapping_result_;
|
| +
|
| InlineTextBox* text_box_ = nullptr;
|
|
|
| // Remember if we are in the middle of handling a pre-formatted text node.
|
|
|