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

Unified Diff: third_party/WebKit/Source/core/layout/LayoutObject.cpp

Issue 2916493002: Make SelectionState enum class (Closed)
Patch Set: Created 3 years, 7 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
Index: third_party/WebKit/Source/core/layout/LayoutObject.cpp
diff --git a/third_party/WebKit/Source/core/layout/LayoutObject.cpp b/third_party/WebKit/Source/core/layout/LayoutObject.cpp
index 1f6b5b5071ca4500bf4c890398d96d45b2429af7..adc7d6f538689fc9e5e10004261cb65b56b69546 100644
--- a/third_party/WebKit/Source/core/layout/LayoutObject.cpp
+++ b/third_party/WebKit/Source/core/layout/LayoutObject.cpp
@@ -2592,7 +2592,8 @@ inline LayoutObject* LayoutObject::ParentCrossingFrames() const {
bool LayoutObject::IsSelectionBorder() const {
SelectionState st = GetSelectionState();
- return st == SelectionStart || st == SelectionEnd || st == SelectionBoth;
+ return st == SelectionState::kStart || st == SelectionState::kEnd ||
+ st == SelectionState::kStartAndEnd;
}
inline void LayoutObject::ClearLayoutRootIfNeeded() const {
@@ -3609,7 +3610,7 @@ void LayoutObject::InvalidatePaintForSelection() {
child = child->NextSibling()) {
if (!child->CanBeSelectionLeaf())
continue;
- if (child->GetSelectionState() == SelectionNone)
+ if (child->GetSelectionState() == SelectionState::kNone)
continue;
child->SetShouldInvalidateSelection();
}
« no previous file with comments | « third_party/WebKit/Source/core/layout/LayoutObject.h ('k') | third_party/WebKit/Source/core/layout/LayoutReplaced.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698