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

Side by Side Diff: chrome/browser/extensions/api/webrtc_audio_private/webrtc_audio_private_api.cc

Issue 1445003002: Use std::default_delete as the default deleter for scoped_ptr. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix Windows Created 5 years, 1 month 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 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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/extensions/api/webrtc_audio_private/webrtc_audio_privat e_api.h" 5 #include "chrome/browser/extensions/api/webrtc_audio_private/webrtc_audio_privat e_api.h"
6 6
7 #include "base/lazy_instance.h" 7 #include "base/lazy_instance.h"
8 #include "base/strings/string_number_conversions.h" 8 #include "base/strings/string_number_conversions.h"
9 #include "base/task_runner_util.h" 9 #include "base/task_runner_util.h"
10 #include "chrome/browser/extensions/api/tabs/tabs_constants.h" 10 #include "chrome/browser/extensions/api/tabs/tabs_constants.h"
(...skipping 103 matching lines...) Expand 10 before | Expand all | Expand 10 after
114 audio_manager_runner->PostTask( 114 audio_manager_runner->PostTask(
115 FROM_HERE, 115 FROM_HERE,
116 base::Bind(&WebrtcAudioPrivateFunction::GetOutputDeviceNames, this)); 116 base::Bind(&WebrtcAudioPrivateFunction::GetOutputDeviceNames, this));
117 return; 117 return;
118 } 118 }
119 119
120 scoped_ptr<AudioDeviceNames> device_names(new AudioDeviceNames); 120 scoped_ptr<AudioDeviceNames> device_names(new AudioDeviceNames);
121 AudioManager::Get()->GetAudioOutputDeviceNames(device_names.get()); 121 AudioManager::Get()->GetAudioOutputDeviceNames(device_names.get());
122 122
123 BrowserThread::PostTask( 123 BrowserThread::PostTask(
124 BrowserThread::IO, 124 BrowserThread::IO, FROM_HERE,
125 FROM_HERE, 125 base::Bind(&WebrtcAudioPrivateFunction::OnOutputDeviceNames, this,
126 base::Bind(&WebrtcAudioPrivateFunction::OnOutputDeviceNames, 126 base::Passed(&device_names)));
dcheng 2015/11/16 18:22:59 I have no idea how this compiled before.
127 this,
128 Passed(&device_names)));
129 } 127 }
130 128
131 void WebrtcAudioPrivateFunction::OnOutputDeviceNames( 129 void WebrtcAudioPrivateFunction::OnOutputDeviceNames(
132 scoped_ptr<AudioDeviceNames> device_names) { 130 scoped_ptr<AudioDeviceNames> device_names) {
133 NOTREACHED(); 131 NOTREACHED();
134 } 132 }
135 133
136 bool WebrtcAudioPrivateFunction::GetControllerList(const RequestInfo& request) { 134 bool WebrtcAudioPrivateFunction::GetControllerList(const RequestInfo& request) {
137 content::RenderProcessHost* rph = nullptr; 135 content::RenderProcessHost* rph = nullptr;
138 136
(...skipping 365 matching lines...) Expand 10 before | Expand all | Expand 10 after
504 results_.reset(wap::GetAssociatedSink::Results::Create("").release()); 502 results_.reset(wap::GetAssociatedSink::Results::Create("").release());
505 } else { 503 } else {
506 results_.reset( 504 results_.reset(
507 wap::GetAssociatedSink::Results::Create(associated_sink_id).release()); 505 wap::GetAssociatedSink::Results::Create(associated_sink_id).release());
508 } 506 }
509 507
510 SendResponse(true); 508 SendResponse(true);
511 } 509 }
512 510
513 } // namespace extensions 511 } // namespace extensions
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698