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

Side by Side Diff: third_party/WebKit/Source/core/editing/Editor.cpp

Issue 2082503003: ASSERT -> DCHECK conversions in core/editing. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 6 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 unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2006, 2007, 2008, 2011 Apple Inc. All rights reserved. 2 * Copyright (C) 2006, 2007, 2008, 2011 Apple Inc. All rights reserved.
3 * Copyright (C) 2008 Nokia Corporation and/or its subsidiary(-ies) 3 * Copyright (C) 2008 Nokia Corporation and/or its subsidiary(-ies)
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions 6 * modification, are permitted provided that the following conditions
7 * are met: 7 * are met:
8 * 1. Redistributions of source code must retain the above copyright 8 * 1. Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * 2. Redistributions in binary form must reproduce the above copyright 10 * 2. Redistributions in binary form must reproduce the above copyright
(...skipping 1221 matching lines...) Expand 10 before | Expand all | Expand 10 after
1232 // return such section as a Range, we skip this match and seek for the 1232 // return such section as a Range, we skip this match and seek for the
1233 // next occurrence. 1233 // next occurrence.
1234 // TODO(yosin) Handle this case. 1234 // TODO(yosin) Handle this case.
1235 if (forward) { 1235 if (forward) {
1236 searchRange = EphemeralRangeTemplate<Strategy>(nextPositionOf(result Range.startPosition(), PositionMoveType::GraphemeCluster), searchRange.endPositi on()); 1236 searchRange = EphemeralRangeTemplate<Strategy>(nextPositionOf(result Range.startPosition(), PositionMoveType::GraphemeCluster), searchRange.endPositi on());
1237 } else { 1237 } else {
1238 searchRange = EphemeralRangeTemplate<Strategy>(searchRange.startPosi tion(), previousPositionOf(resultRange.endPosition(), PositionMoveType::Grapheme Cluster)); 1238 searchRange = EphemeralRangeTemplate<Strategy>(searchRange.startPosi tion(), previousPositionOf(resultRange.endPosition(), PositionMoveType::Grapheme Cluster));
1239 } 1239 }
1240 } 1240 }
1241 1241
1242 ASSERT_NOT_REACHED(); 1242 NOTREACHED();
1243 return nullptr; 1243 return nullptr;
1244 } 1244 }
1245 1245
1246 template <typename Strategy> 1246 template <typename Strategy>
1247 static Range* findRangeOfStringAlgorithm(Document& document, const String& targe t, const EphemeralRangeTemplate<Strategy>& referenceRange, FindOptions options) 1247 static Range* findRangeOfStringAlgorithm(Document& document, const String& targe t, const EphemeralRangeTemplate<Strategy>& referenceRange, FindOptions options)
1248 { 1248 {
1249 if (target.isEmpty()) 1249 if (target.isEmpty())
1250 return nullptr; 1250 return nullptr;
1251 1251
1252 // Start from an edge of the reference range. Which edge is used depends on 1252 // Start from an edge of the reference range. Which edge is used depends on
(...skipping 117 matching lines...) Expand 10 before | Expand all | Expand 10 after
1370 } 1370 }
1371 1371
1372 DEFINE_TRACE(Editor) 1372 DEFINE_TRACE(Editor)
1373 { 1373 {
1374 visitor->trace(m_frame); 1374 visitor->trace(m_frame);
1375 visitor->trace(m_lastEditCommand); 1375 visitor->trace(m_lastEditCommand);
1376 visitor->trace(m_mark); 1376 visitor->trace(m_mark);
1377 } 1377 }
1378 1378
1379 } // namespace blink 1379 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/editing/EditingUtilities.cpp ('k') | third_party/WebKit/Source/core/editing/EphemeralRange.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698