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

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

Issue 1686483002: Oilpan: Remove most WillBe types from the code base (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 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/EditingUtilities.cpp
diff --git a/third_party/WebKit/Source/core/editing/EditingUtilities.cpp b/third_party/WebKit/Source/core/editing/EditingUtilities.cpp
index ee40e3732833188fb54b6cf9016de93a3ec0c71b..4932c41b70bb1f96c742a9b0a8183b450b0dc8ba 100644
--- a/third_party/WebKit/Source/core/editing/EditingUtilities.cpp
+++ b/third_party/WebKit/Source/core/editing/EditingUtilities.cpp
@@ -1262,7 +1262,7 @@ bool isEmptyTableCell(const Node* node)
return !childLayoutObject->nextSibling();
}
-PassRefPtrWillBeRawPtr<HTMLElement> createDefaultParagraphElement(Document& document)
+RawPtr<HTMLElement> createDefaultParagraphElement(Document& document)
{
switch (document.frame()->editor().defaultParagraphSeparator()) {
case EditorParagraphSeparatorIsDiv:
@@ -1275,7 +1275,7 @@ PassRefPtrWillBeRawPtr<HTMLElement> createDefaultParagraphElement(Document& docu
return nullptr;
}
-PassRefPtrWillBeRawPtr<HTMLElement> createHTMLElement(Document& document, const QualifiedName& name)
+RawPtr<HTMLElement> createHTMLElement(Document& document, const QualifiedName& name)
{
return HTMLElementFactory::createHTMLElement(name.localName(), document, 0, false);
}
@@ -1298,12 +1298,12 @@ HTMLSpanElement* tabSpanElement(const Node* node)
return isTabHTMLSpanElementTextNode(node) ? toHTMLSpanElement(node->parentNode()) : 0;
}
-static PassRefPtrWillBeRawPtr<HTMLSpanElement> createTabSpanElement(Document& document, PassRefPtrWillBeRawPtr<Text> prpTabTextNode)
+static RawPtr<HTMLSpanElement> createTabSpanElement(Document& document, RawPtr<Text> prpTabTextNode)
{
- RefPtrWillBeRawPtr<Text> tabTextNode = prpTabTextNode;
+ RawPtr<Text> tabTextNode = prpTabTextNode;
// Make the span to hold the tab.
- RefPtrWillBeRawPtr<HTMLSpanElement> spanElement = HTMLSpanElement::create(document);
+ RawPtr<HTMLSpanElement> spanElement = HTMLSpanElement::create(document);
spanElement->setAttribute(classAttr, AppleTabSpanClass);
spanElement->setAttribute(styleAttr, "white-space:pre");
@@ -1316,14 +1316,14 @@ static PassRefPtrWillBeRawPtr<HTMLSpanElement> createTabSpanElement(Document& do
return spanElement.release();
}
-PassRefPtrWillBeRawPtr<HTMLSpanElement> createTabSpanElement(Document& document, const String& tabText)
+RawPtr<HTMLSpanElement> createTabSpanElement(Document& document, const String& tabText)
{
return createTabSpanElement(document, document.createTextNode(tabText));
}
-PassRefPtrWillBeRawPtr<HTMLSpanElement> createTabSpanElement(Document& document)
+RawPtr<HTMLSpanElement> createTabSpanElement(Document& document)
{
- return createTabSpanElement(document, PassRefPtrWillBeRawPtr<Text>(nullptr));
+ return createTabSpanElement(document, RawPtr<Text>(nullptr));
}
bool isNodeRendered(const Node& node)
@@ -1514,7 +1514,7 @@ VisibleSelection selectionForParagraphIteration(const VisibleSelection& original
// opertion is unreliable. TextIterator's TextIteratorEmitsCharactersBetweenAllVisiblePositions mode needs to be fixed,
// or these functions need to be changed to iterate using actual VisiblePositions.
// FIXME: Deploy these functions everywhere that TextIterators are used to convert between VisiblePositions and indices.
-int indexForVisiblePosition(const VisiblePosition& visiblePosition, RefPtrWillBeRawPtr<ContainerNode>& scope)
+int indexForVisiblePosition(const VisiblePosition& visiblePosition, RawPtr<ContainerNode>& scope)
{
if (visiblePosition.isNull())
return 0;
@@ -1528,7 +1528,7 @@ int indexForVisiblePosition(const VisiblePosition& visiblePosition, RefPtrWillBe
else
scope = document.documentElement();
- RefPtrWillBeRawPtr<Range> range = Range::create(document, firstPositionInNode(scope.get()), p.parentAnchoredEquivalent());
+ RawPtr<Range> range = Range::create(document, firstPositionInNode(scope.get()), p.parentAnchoredEquivalent());
return TextIterator::rangeLength(range->startPosition(), range->endPosition(), true);
}

Powered by Google App Engine
This is Rietveld 408576698