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

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

Issue 2704123003: Expand FrameSeleciton::isCaret() to increase chances of hoisting update layout (Closed)
Patch Set: 2017-02-21T12:50:46 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
Index: third_party/WebKit/Source/core/editing/FrameSelection.cpp
diff --git a/third_party/WebKit/Source/core/editing/FrameSelection.cpp b/third_party/WebKit/Source/core/editing/FrameSelection.cpp
index 5ac8645713e1f005791ee6f80195d09decf46dce..7a0fa9a8dbdd5f6af3258dc8d58393e55bcee9a1 100644
--- a/third_party/WebKit/Source/core/editing/FrameSelection.cpp
+++ b/third_party/WebKit/Source/core/editing/FrameSelection.cpp
@@ -480,7 +480,8 @@ void FrameSelection::invalidatePaintIfNeeded(
bool FrameSelection::shouldPaintCaret(const LayoutBlock& block) const {
DCHECK_GE(document().lifecycle().state(), DocumentLifecycle::LayoutClean);
bool result = m_frameCaret->shouldPaintCaret(block);
- DCHECK(!result || (isCaret() && hasEditableStyle()));
+ DCHECK(!result || (computeVisibleSelectionInDOMTreeDeprecated().isCaret() &&
+ hasEditableStyle()));
return result;
}
« no previous file with comments | « third_party/WebKit/Source/core/editing/FrameSelection.h ('k') | third_party/WebKit/Source/core/editing/FrameSelectionTest.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698