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

Unified Diff: third_party/WebKit/Source/core/editing/SelectionTemplate.cpp

Issue 2646963002: Stop dismissing selection handles when selection is kept (Closed)
Patch Set: avoid control flow in IMC and rebase Created 3 years, 11 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/editing/SelectionTemplate.cpp
diff --git a/third_party/WebKit/Source/core/editing/SelectionTemplate.cpp b/third_party/WebKit/Source/core/editing/SelectionTemplate.cpp
index d3652e72edd936085f1a834a86da4de45947c616..853adf7b996dbab62cc426ed2eff2345e8f0bff4 100644
--- a/third_party/WebKit/Source/core/editing/SelectionTemplate.cpp
+++ b/third_party/WebKit/Source/core/editing/SelectionTemplate.cpp
@@ -16,7 +16,8 @@ SelectionTemplate<Strategy>::SelectionTemplate(const SelectionTemplate& other)
m_affinity(other.m_affinity),
m_granularity(other.m_granularity),
m_hasTrailingWhitespace(other.m_hasTrailingWhitespace),
- m_isDirectional(other.m_isDirectional)
+ m_isDirectional(other.m_isDirectional),
+ m_isHandleVisible(other.m_isHandleVisible)
yosin_UTC9 2017/01/25 03:49:08 Please move this change in another patch and test
Changwan Ryu 2017/02/08 00:40:33 This is fixed in amaralp@'s patch.
#if DCHECK_IS_ON()
,
m_domTreeVersion(other.m_domTreeVersion)
@@ -45,7 +46,8 @@ bool SelectionTemplate<Strategy>::operator==(
m_affinity == other.m_affinity &&
m_granularity == other.m_granularity &&
m_hasTrailingWhitespace == other.m_hasTrailingWhitespace &&
- m_isDirectional == other.m_isDirectional;
+ m_isDirectional == other.m_isDirectional &&
+ m_isHandleVisible == other.m_isHandleVisible;
}
template <typename Strategy>
@@ -285,6 +287,13 @@ SelectionTemplate<Strategy>::Builder::setIsDirectional(bool isDirectional) {
return *this;
}
+template <typename Strategy>
+typename SelectionTemplate<Strategy>::Builder&
+SelectionTemplate<Strategy>::Builder::setIsHandleVisible(bool isHandleVisible) {
+ m_selection.m_isHandleVisible = isHandleVisible;
+ return *this;
+}
+
template class CORE_TEMPLATE_EXPORT SelectionTemplate<EditingStrategy>;
template class CORE_TEMPLATE_EXPORT
SelectionTemplate<EditingInFlatTreeStrategy>;

Powered by Google App Engine
This is Rietveld 408576698