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

Unified Diff: third_party/WebKit/Source/modules/webaudio/AudioParamTimeline.cpp

Issue 2776203002: Migrate WTF::Vector::remove() to ::erase() (Closed)
Patch Set: rebase, repatch VectorTest 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/modules/webaudio/AudioParamTimeline.cpp
diff --git a/third_party/WebKit/Source/modules/webaudio/AudioParamTimeline.cpp b/third_party/WebKit/Source/modules/webaudio/AudioParamTimeline.cpp
index 3cf140fca57cfc4e26cc891520961dae24c2b3e8..d583a198e6a8a35551cd42d0e55dbdf60c91b525 100644
--- a/third_party/WebKit/Source/modules/webaudio/AudioParamTimeline.cpp
+++ b/third_party/WebKit/Source/modules/webaudio/AudioParamTimeline.cpp
@@ -612,7 +612,7 @@ void AudioParamTimeline::cancelScheduledValues(double startTime,
// Remove all events starting at startTime.
for (unsigned i = 0; i < m_events.size(); ++i) {
if (m_events[i]->time() >= startTime) {
- m_events.remove(i, m_events.size() - i);
+ m_events.erase(i, m_events.size() - i);
break;
}
}
@@ -724,7 +724,7 @@ void AudioParamTimeline::cancelAndHoldAtTime(double cancelTime,
// Now remove all the following events from the timeline.
if (cancelledEventIndex < m_events.size())
- m_events.remove(cancelledEventIndex, m_events.size() - cancelledEventIndex);
+ m_events.erase(cancelledEventIndex, m_events.size() - cancelledEventIndex);
// Insert the new event, if any.
if (newEvent) {
@@ -967,7 +967,7 @@ float AudioParamTimeline::valuesForFrameRangeImpl(size_t startFrame,
// running with the m_events lock so we can safely modify the m_events
// array.)
if (lastSkippedEventIndex > 0)
- m_events.remove(0, lastSkippedEventIndex - 1);
+ m_events.erase(0, lastSkippedEventIndex - 1);
// If there's any time left after processing the last event then just
// propagate the last value to the end of the values buffer.

Powered by Google App Engine
This is Rietveld 408576698