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

Side by Side Diff: extensions/renderer/api/display_source/display_source_session.cc

Issue 1899083003: Convert //extensions/renderer from scoped_ptr to std::unique_ptr (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase Created 4 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 // 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 "extensions/renderer/api/display_source/display_source_session.h" 5 #include "extensions/renderer/api/display_source/display_source_session.h"
6 6
7 #if defined(ENABLE_WIFI_DISPLAY) 7 #if defined(ENABLE_WIFI_DISPLAY)
8 #include "extensions/renderer/api/display_source/wifi_display/wifi_display_sessi on.h" 8 #include "extensions/renderer/api/display_source/wifi_display/wifi_display_sessi on.h"
9 #endif 9 #endif
10 10
(...skipping 17 matching lines...) Expand all
28 void DisplaySourceSession::SetNotificationCallbacks( 28 void DisplaySourceSession::SetNotificationCallbacks(
29 const base::Closure& terminated_callback, 29 const base::Closure& terminated_callback,
30 const ErrorCallback& error_callback) { 30 const ErrorCallback& error_callback) {
31 DCHECK(terminated_callback_.is_null()); 31 DCHECK(terminated_callback_.is_null());
32 DCHECK(error_callback_.is_null()); 32 DCHECK(error_callback_.is_null());
33 33
34 terminated_callback_ = terminated_callback; 34 terminated_callback_ = terminated_callback;
35 error_callback_ = error_callback; 35 error_callback_ = error_callback;
36 } 36 }
37 37
38 scoped_ptr<DisplaySourceSession> DisplaySourceSessionFactory::CreateSession( 38 std::unique_ptr<DisplaySourceSession>
39 DisplaySourceSessionFactory::CreateSession(
39 const DisplaySourceSessionParams& params) { 40 const DisplaySourceSessionParams& params) {
40 #if defined(ENABLE_WIFI_DISPLAY) 41 #if defined(ENABLE_WIFI_DISPLAY)
41 return scoped_ptr<DisplaySourceSession>(new WiFiDisplaySession(params)); 42 return std::unique_ptr<DisplaySourceSession>(new WiFiDisplaySession(params));
42 #endif 43 #endif
43 return nullptr; 44 return nullptr;
44 } 45 }
45 46
46 } // namespace extensions 47 } // namespace extensions
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698