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

Side by Side Diff: third_party/WebKit/Source/web/ChromeClientImpl.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) 2009 Google Inc. All rights reserved. 2 * Copyright (C) 2009 Google Inc. All rights reserved.
3 * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies). 3 * Copyright (C) 2010 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 are 6 * modification, are permitted provided that the following conditions are
7 * met: 7 * met:
8 * 8 *
9 * * Redistributions of source code must retain the above copyright 9 * * Redistributions of source code must retain the above copyright
10 * notice, this list of conditions and the following disclaimer. 10 * notice, this list of conditions and the following disclaimer.
(...skipping 1166 matching lines...) Expand 10 before | Expand all | Expand 10 after
1177 void ChromeClientImpl::registerPopupOpeningObserver( 1177 void ChromeClientImpl::registerPopupOpeningObserver(
1178 PopupOpeningObserver* observer) { 1178 PopupOpeningObserver* observer) {
1179 DCHECK(observer); 1179 DCHECK(observer);
1180 m_popupOpeningObservers.push_back(observer); 1180 m_popupOpeningObservers.push_back(observer);
1181 } 1181 }
1182 1182
1183 void ChromeClientImpl::unregisterPopupOpeningObserver( 1183 void ChromeClientImpl::unregisterPopupOpeningObserver(
1184 PopupOpeningObserver* observer) { 1184 PopupOpeningObserver* observer) {
1185 size_t index = m_popupOpeningObservers.find(observer); 1185 size_t index = m_popupOpeningObservers.find(observer);
1186 DCHECK_NE(index, kNotFound); 1186 DCHECK_NE(index, kNotFound);
1187 m_popupOpeningObservers.remove(index); 1187 m_popupOpeningObservers.erase(index);
1188 } 1188 }
1189 1189
1190 void ChromeClientImpl::notifyPopupOpeningObservers() const { 1190 void ChromeClientImpl::notifyPopupOpeningObservers() const {
1191 const Vector<PopupOpeningObserver*> observers(m_popupOpeningObservers); 1191 const Vector<PopupOpeningObserver*> observers(m_popupOpeningObservers);
1192 for (const auto& observer : observers) 1192 for (const auto& observer : observers)
1193 observer->willOpenPopup(); 1193 observer->willOpenPopup();
1194 } 1194 }
1195 1195
1196 FloatSize ChromeClientImpl::elasticOverscroll() const { 1196 FloatSize ChromeClientImpl::elasticOverscroll() const {
1197 return m_webView->elasticOverscroll(); 1197 return m_webView->elasticOverscroll();
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
1230 PresentationController::provideTo(frame, client->presentationClient()); 1230 PresentationController::provideTo(frame, client->presentationClient());
1231 if (RuntimeEnabledFeatures::audioOutputDevicesEnabled()) { 1231 if (RuntimeEnabledFeatures::audioOutputDevicesEnabled()) {
1232 provideAudioOutputDeviceClientTo(frame, 1232 provideAudioOutputDeviceClientTo(frame,
1233 new AudioOutputDeviceClientImpl(frame)); 1233 new AudioOutputDeviceClientImpl(frame));
1234 } 1234 }
1235 if (RuntimeEnabledFeatures::installedAppEnabled()) 1235 if (RuntimeEnabledFeatures::installedAppEnabled())
1236 InstalledAppController::provideTo(frame, client->getRelatedAppsFetcher()); 1236 InstalledAppController::provideTo(frame, client->getRelatedAppsFetcher());
1237 } 1237 }
1238 1238
1239 } // namespace blink 1239 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/platform/wtf/Vector.h ('k') | third_party/WebKit/Source/wtf/VectorTest.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698