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

Side by Side Diff: components/component_updater/component_updater_service.cc

Issue 2257793002: Re-write many calls to WrapUnique() with MakeUnique() (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase Created 4 years, 3 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 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 "components/component_updater/component_updater_service.h" 5 #include "components/component_updater/component_updater_service.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <map> 8 #include <map>
9 #include <string> 9 #include <string>
10 #include <utility> 10 #include <utility>
(...skipping 438 matching lines...) Expand 10 before | Expand all | Expand 10 after
449 449
450 /////////////////////////////////////////////////////////////////////////////// 450 ///////////////////////////////////////////////////////////////////////////////
451 451
452 // The component update factory. Using the component updater as a singleton 452 // The component update factory. Using the component updater as a singleton
453 // is the job of the browser process. 453 // is the job of the browser process.
454 // TODO(sorin): consider making this a singleton. 454 // TODO(sorin): consider making this a singleton.
455 std::unique_ptr<ComponentUpdateService> ComponentUpdateServiceFactory( 455 std::unique_ptr<ComponentUpdateService> ComponentUpdateServiceFactory(
456 const scoped_refptr<Configurator>& config) { 456 const scoped_refptr<Configurator>& config) {
457 DCHECK(config); 457 DCHECK(config);
458 auto update_client = update_client::UpdateClientFactory(config); 458 auto update_client = update_client::UpdateClientFactory(config);
459 return base::WrapUnique( 459 return base::MakeUnique<CrxUpdateService>(config, std::move(update_client));
460 new CrxUpdateService(config, std::move(update_client)));
461 } 460 }
462 461
463 } // namespace component_updater 462 } // namespace component_updater
OLDNEW
« no previous file with comments | « components/certificate_reporting/error_reporter.cc ('k') | components/component_updater/component_updater_service_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698