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

Unified Diff: third_party/WebKit/Source/core/page/scrolling/ScrollingCoordinator.cpp

Issue 2693433002: Migrate WTF::HashMap::add() to ::insert() [final] (Closed)
Patch Set: more platform-specific references 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/page/scrolling/ScrollingCoordinator.cpp
diff --git a/third_party/WebKit/Source/core/page/scrolling/ScrollingCoordinator.cpp b/third_party/WebKit/Source/core/page/scrolling/ScrollingCoordinator.cpp
index 51b10e24748ddddfb51758cb39ff925bfb6013e2..96fea433050e14bdac5c888154a5b51b73ed393b 100644
--- a/third_party/WebKit/Source/core/page/scrolling/ScrollingCoordinator.cpp
+++ b/third_party/WebKit/Source/core/page/scrolling/ScrollingCoordinator.cpp
@@ -398,7 +398,7 @@ WebScrollbarLayer* ScrollingCoordinator::addWebScrollbarLayer(
ScrollbarMap& scrollbars = orientation == HorizontalScrollbar
? m_horizontalScrollbars
: m_verticalScrollbars;
- return scrollbars.add(scrollableArea, std::move(scrollbarLayer))
+ return scrollbars.insert(scrollableArea, std::move(scrollbarLayer))
.storedValue->value.get();
}
@@ -558,7 +558,7 @@ static void makeLayerChildFrameMap(const LocalFrame* currentFrame,
const PaintLayer* containingLayer = ownerLayoutItem.enclosingLayer();
LayerFrameMap::iterator iter = map->find(containingLayer);
if (iter == map->end())
- map->add(containingLayer, HeapVector<Member<const LocalFrame>>())
+ map->insert(containingLayer, HeapVector<Member<const LocalFrame>>())
.storedValue->value.push_back(toLocalFrame(child));
else
iter->value.push_back(toLocalFrame(child));
@@ -594,7 +594,7 @@ static void projectRectsToGraphicsLayerSpaceRecursive(
graphicsRects.find(graphicsLayer);
Vector<LayoutRect>* glRects;
if (glIter == graphicsRects.end())
- glRects = &graphicsRects.add(graphicsLayer, Vector<LayoutRect>())
+ glRects = &graphicsRects.insert(graphicsLayer, Vector<LayoutRect>())
.storedValue->value;
else
glRects = &glIter->value;
@@ -749,10 +749,10 @@ void ScrollingCoordinator::setTouchEventTargetRects(
GraphicsLayer* mainGraphicsLayer =
layer->graphicsLayerBacking(layer->layoutObject());
if (mainGraphicsLayer)
- graphicsLayerRects.add(mainGraphicsLayer, Vector<LayoutRect>());
+ graphicsLayerRects.insert(mainGraphicsLayer, Vector<LayoutRect>());
GraphicsLayer* scrollingContentsLayer = layer->graphicsLayerBacking();
if (scrollingContentsLayer && scrollingContentsLayer != mainGraphicsLayer)
- graphicsLayerRects.add(scrollingContentsLayer, Vector<LayoutRect>());
+ graphicsLayerRects.insert(scrollingContentsLayer, Vector<LayoutRect>());
}
m_layersWithTouchRects.clear();

Powered by Google App Engine
This is Rietveld 408576698