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

Side by Side Diff: chromecast/browser/url_request_context_factory.cc

Issue 2745053002: Replace unique_ptr.reset(other_unique_ptr.release()) with std::move() in chromecast/ (Closed)
Patch Set: Created 3 years, 9 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
« no previous file with comments | « no previous file | chromecast/media/cma/test/mock_frame_consumer.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 "chromecast/browser/url_request_context_factory.h" 5 #include "chromecast/browser/url_request_context_factory.h"
6 6
7 #include <utility> 7 #include <utility>
8 8
9 #include "base/command_line.h" 9 #include "base/command_line.h"
10 #include "base/files/file_path.h" 10 #include "base/files/file_path.h"
(...skipping 285 matching lines...) Expand 10 before | Expand all | Expand 10 after
296 // Set up interceptors in the reverse order. 296 // Set up interceptors in the reverse order.
297 std::unique_ptr<net::URLRequestJobFactory> top_job_factory = 297 std::unique_ptr<net::URLRequestJobFactory> top_job_factory =
298 std::move(job_factory); 298 std::move(job_factory);
299 for (auto i = request_interceptors.rbegin(); i != request_interceptors.rend(); 299 for (auto i = request_interceptors.rbegin(); i != request_interceptors.rend();
300 ++i) { 300 ++i) {
301 top_job_factory.reset(new net::URLRequestInterceptingJobFactory( 301 top_job_factory.reset(new net::URLRequestInterceptingJobFactory(
302 std::move(top_job_factory), std::move(*i))); 302 std::move(top_job_factory), std::move(*i)));
303 } 303 }
304 request_interceptors.clear(); 304 request_interceptors.clear();
305 305
306 main_job_factory_.reset(top_job_factory.release()); 306 main_job_factory_ = std::move(top_job_factory);
307 307
308 main_dependencies_initialized_ = true; 308 main_dependencies_initialized_ = true;
309 } 309 }
310 310
311 void URLRequestContextFactory::InitializeMediaContextDependencies( 311 void URLRequestContextFactory::InitializeMediaContextDependencies(
312 net::HttpTransactionFactory* transaction_factory) { 312 net::HttpTransactionFactory* transaction_factory) {
313 if (media_dependencies_initialized_) 313 if (media_dependencies_initialized_)
314 return; 314 return;
315 315
316 media_transaction_factory_.reset(transaction_factory); 316 media_transaction_factory_.reset(transaction_factory);
(...skipping 155 matching lines...) Expand 10 before | Expand all | Expand 10 after
472 if (media_getter_) { 472 if (media_getter_) {
473 media_getter_->GetURLRequestContext() 473 media_getter_->GetURLRequestContext()
474 ->http_transaction_factory() 474 ->http_transaction_factory()
475 ->GetSession() 475 ->GetSession()
476 ->DisableQuic(); 476 ->DisableQuic();
477 } 477 }
478 } 478 }
479 479
480 } // namespace shell 480 } // namespace shell
481 } // namespace chromecast 481 } // namespace chromecast
OLDNEW
« no previous file with comments | « no previous file | chromecast/media/cma/test/mock_frame_consumer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698