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

Side by Side Diff: chrome/browser/media/permission_bubble_media_access_handler.cc

Issue 1551033002: Convert Pass()→std::move() in //chrome (Android edition) (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Enable RVO by making types match Created 4 years, 11 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 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/browser/media/permission_bubble_media_access_handler.h" 5 #include "chrome/browser/media/permission_bubble_media_access_handler.h"
6 6
7 #include <utility> 7 #include <utility>
8 8
9 #include "base/metrics/field_trial.h" 9 #include "base/metrics/field_trial.h"
10 #include "chrome/browser/media/media_permission.h" 10 #include "chrome/browser/media/media_permission.h"
(...skipping 151 matching lines...) Expand 10 before | Expand all | Expand 10 after
162 PermissionUpdateInfoBarDelegate::Create( 162 PermissionUpdateInfoBarDelegate::Create(
163 web_contents, content_settings_types, 163 web_contents, content_settings_types,
164 base::Bind( 164 base::Bind(
165 &OnPermissionConflictResolved, base::Passed(&controller))); 165 &OnPermissionConflictResolved, base::Passed(&controller)));
166 } 166 }
167 #endif 167 #endif
168 return; 168 return;
169 } 169 }
170 170
171 #if BUILDFLAG(ANDROID_JAVA_UI) 171 #if BUILDFLAG(ANDROID_JAVA_UI)
172 MediaStreamInfoBarDelegateAndroid::Create(web_contents, controller.Pass()); 172 MediaStreamInfoBarDelegateAndroid::Create(web_contents,
173 std::move(controller));
173 #else 174 #else
174 PermissionBubbleManager* bubble_manager = 175 PermissionBubbleManager* bubble_manager =
175 PermissionBubbleManager::FromWebContents(web_contents); 176 PermissionBubbleManager::FromWebContents(web_contents);
176 if (bubble_manager) 177 if (bubble_manager)
177 bubble_manager->AddRequest(controller.release()); 178 bubble_manager->AddRequest(controller.release());
178 #endif 179 #endif
179 } 180 }
180 181
181 void PermissionBubbleMediaAccessHandler::UpdateMediaRequestState( 182 void PermissionBubbleMediaAccessHandler::UpdateMediaRequestState(
182 int render_process_id, 183 int render_process_id,
(...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after
245 int type, 246 int type,
246 const content::NotificationSource& source, 247 const content::NotificationSource& source,
247 const content::NotificationDetails& details) { 248 const content::NotificationDetails& details) {
248 DCHECK_CURRENTLY_ON(BrowserThread::UI); 249 DCHECK_CURRENTLY_ON(BrowserThread::UI);
249 if (type == content::NOTIFICATION_WEB_CONTENTS_DESTROYED) { 250 if (type == content::NOTIFICATION_WEB_CONTENTS_DESTROYED) {
250 content::WebContents* web_contents = 251 content::WebContents* web_contents =
251 content::Source<content::WebContents>(source).ptr(); 252 content::Source<content::WebContents>(source).ptr();
252 pending_requests_.erase(web_contents); 253 pending_requests_.erase(web_contents);
253 } 254 }
254 } 255 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698