Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(492)

Unified Diff: third_party/WebKit/Source/core/layout/ng/ng_break_token.h

Issue 2706353004: [LayoutNG] Introduce block child iterator. (Closed)
Patch Set: address comments. Created 3 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « third_party/WebKit/Source/core/layout/ng/ng_block_child_iterator_test.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/core/layout/ng/ng_break_token.h
diff --git a/third_party/WebKit/Source/core/layout/ng/ng_break_token.h b/third_party/WebKit/Source/core/layout/ng/ng_break_token.h
index 15f0b1e0399a080538559f3e1994f9b871792f81..94fb6d19a6e7a226557f3ef0ff6e94878dc2bd4d 100644
--- a/third_party/WebKit/Source/core/layout/ng/ng_break_token.h
+++ b/third_party/WebKit/Source/core/layout/ng/ng_break_token.h
@@ -39,8 +39,10 @@ class CORE_EXPORT NGBreakToken
enum NGBreakTokenType { kBlockBreakToken, kTextBreakToken };
NGBreakTokenType Type() const { return static_cast<NGBreakTokenType>(type_); }
+ enum NGBreakTokenStatus { kUnfinished, kFinished };
+
// Whether the layout node cannot produce any more fragments.
- bool IsFinished() const { return is_finished_; }
+ bool IsFinished() const { return status_ == kFinished; }
// Returns the node associated with this break token. A break token cannot be
// used with any other node.
@@ -49,12 +51,14 @@ class CORE_EXPORT NGBreakToken
DEFINE_INLINE_VIRTUAL_TRACE() { visitor->trace(node_); }
protected:
- NGBreakToken(NGBreakTokenType type, bool is_finished, NGLayoutInputNode* node)
- : type_(type), is_finished_(is_finished), node_(node) {}
+ NGBreakToken(NGBreakTokenType type,
+ NGBreakTokenStatus status,
+ NGLayoutInputNode* node)
+ : type_(type), status_(status), node_(node) {}
private:
unsigned type_ : 1;
- unsigned is_finished_ : 1;
+ unsigned status_ : 1;
Member<NGLayoutInputNode> node_;
};
« no previous file with comments | « third_party/WebKit/Source/core/layout/ng/ng_block_child_iterator_test.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698