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

Unified Diff: third_party/WebKit/Source/core/editing/markers/DocumentMarkerController.cpp

Issue 2776103002: Make RenderedRectsForMarkers() to ignore disconnected nodes. (Closed)
Patch Set: change expected image Created 3 years, 9 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/markers/DocumentMarkerController.cpp
diff --git a/third_party/WebKit/Source/core/editing/markers/DocumentMarkerController.cpp b/third_party/WebKit/Source/core/editing/markers/DocumentMarkerController.cpp
index 34506d1809171ca1ef41fdc04d995e252f4aa773..732f9746ef9cdbf6c61b57f605a3823cfe4608db 100644
--- a/third_party/WebKit/Source/core/editing/markers/DocumentMarkerController.cpp
+++ b/third_party/WebKit/Source/core/editing/markers/DocumentMarkerController.cpp
@@ -213,7 +213,7 @@ static void updateMarkerRenderedRect(const Node& node,
range->setEnd(&const_cast<Node&>(node), marker.endOffset(),
IGNORE_EXCEPTION_FOR_TESTING);
}
- if (!exceptionState.hadException()) {
+ if (!exceptionState.hadException() && range->isConnected()) {
yosin_UTC9 2017/04/04 01:20:39 This change should not be in this patch. If we nee
Hwanseung Lee 2017/04/05 15:21:30 Done.
// TODO(yosin): Once we have a |EphemeralRange| version of |boundingBox()|,
// we should use it instead of |Range| version.
marker.setRenderedRect(LayoutRect(range->boundingBox()));
« third_party/WebKit/Source/core/dom/Range.cpp ('K') | « third_party/WebKit/Source/core/dom/Range.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698