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

Side by Side Diff: third_party/WebKit/Source/core/html/HTMLMediaElement.cpp

Issue 2776203002: Migrate WTF::Vector::remove() to ::erase() (Closed)
Patch Set: rebase, repatch VectorTest Created 3 years, 8 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) 2007, 2008, 2009, 2010, 2011, 2012, 2013 Apple Inc. All rights 2 * Copyright (C) 2007, 2008, 2009, 2010, 2011, 2012, 2013 Apple Inc. All rights
3 * reserved. 3 * reserved.
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 2852 matching lines...) Expand 10 before | Expand all | Expand 10 after
2863 return; 2863 return;
2864 2864
2865 // 4.8.12.11.3 Sourcing out-of-band text tracks 2865 // 4.8.12.11.3 Sourcing out-of-band text tracks
2866 // When a track element's parent element changes and the old parent was a 2866 // When a track element's parent element changes and the old parent was a
2867 // media element, then the user agent must remove the track element's 2867 // media element, then the user agent must remove the track element's
2868 // corresponding text track from the media element's list of text tracks. 2868 // corresponding text track from the media element's list of text tracks.
2869 m_textTracks->remove(textTrack); 2869 m_textTracks->remove(textTrack);
2870 2870
2871 size_t index = m_textTracksWhenResourceSelectionBegan.find(textTrack); 2871 size_t index = m_textTracksWhenResourceSelectionBegan.find(textTrack);
2872 if (index != kNotFound) 2872 if (index != kNotFound)
2873 m_textTracksWhenResourceSelectionBegan.remove(index); 2873 m_textTracksWhenResourceSelectionBegan.erase(index);
2874 } 2874 }
2875 2875
2876 void HTMLMediaElement::honorUserPreferencesForAutomaticTextTrackSelection() { 2876 void HTMLMediaElement::honorUserPreferencesForAutomaticTextTrackSelection() {
2877 if (!m_textTracks || !m_textTracks->length()) 2877 if (!m_textTracks || !m_textTracks->length())
2878 return; 2878 return;
2879 2879
2880 if (!m_shouldPerformAutomaticTrackSelection) 2880 if (!m_shouldPerformAutomaticTrackSelection)
2881 return; 2881 return;
2882 2882
2883 AutomaticTrackSelection::Configuration configuration; 2883 AutomaticTrackSelection::Configuration configuration;
(...skipping 1357 matching lines...) Expand 10 before | Expand all | Expand 10 after
4241 kMostlyFillViewportBecomeStableSeconds, BLINK_FROM_HERE); 4241 kMostlyFillViewportBecomeStableSeconds, BLINK_FROM_HERE);
4242 } 4242 }
4243 4243
4244 void HTMLMediaElement::viewportFillDebouncerTimerFired(TimerBase*) { 4244 void HTMLMediaElement::viewportFillDebouncerTimerFired(TimerBase*) {
4245 m_mostlyFillingViewport = true; 4245 m_mostlyFillingViewport = true;
4246 if (m_webMediaPlayer) 4246 if (m_webMediaPlayer)
4247 m_webMediaPlayer->becameDominantVisibleContent(m_mostlyFillingViewport); 4247 m_webMediaPlayer->becameDominantVisibleContent(m_mostlyFillingViewport);
4248 } 4248 }
4249 4249
4250 } // namespace blink 4250 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/html/FormData.cpp ('k') | third_party/WebKit/Source/core/html/TimeRanges.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698