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

Side by Side Diff: chrome/browser/chromeos/extensions/external_cache.cc

Issue 1870793002: Convert //chrome/browser/chromeos from scoped_ptr to std::unique_ptr (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: iwyu fixes 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 (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 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/chromeos/extensions/external_cache.h" 5 #include "chrome/browser/chromeos/extensions/external_cache.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 #include <utility> 8 #include <utility>
9 9
10 #include "base/bind.h" 10 #include "base/bind.h"
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after
63 } 63 }
64 64
65 ExternalCache::~ExternalCache() { 65 ExternalCache::~ExternalCache() {
66 } 66 }
67 67
68 void ExternalCache::Shutdown(const base::Closure& callback) { 68 void ExternalCache::Shutdown(const base::Closure& callback) {
69 local_cache_.Shutdown(callback); 69 local_cache_.Shutdown(callback);
70 } 70 }
71 71
72 void ExternalCache::UpdateExtensionsList( 72 void ExternalCache::UpdateExtensionsList(
73 scoped_ptr<base::DictionaryValue> prefs) { 73 std::unique_ptr<base::DictionaryValue> prefs) {
74 extensions_ = std::move(prefs); 74 extensions_ = std::move(prefs);
75 75
76 if (extensions_->empty()) { 76 if (extensions_->empty()) {
77 // If list of know extensions is empty, don't init cache on disk. It is 77 // If list of know extensions is empty, don't init cache on disk. It is
78 // important shortcut for test to don't wait forever for cache dir 78 // important shortcut for test to don't wait forever for cache dir
79 // initialization that should happen outside of Chrome on real device. 79 // initialization that should happen outside of Chrome on real device.
80 cached_extensions_->Clear(); 80 cached_extensions_->Clear();
81 UpdateExtensionLoader(); 81 UpdateExtensionLoader();
82 return; 82 return;
83 } 83 }
(...skipping 280 matching lines...) Expand 10 before | Expand all | Expand 10 after
364 OnPutExtension(id, file_path, file_ownership_passed); 364 OnPutExtension(id, file_path, file_ownership_passed);
365 callback.Run(id, !file_ownership_passed); 365 callback.Run(id, !file_ownership_passed);
366 } 366 }
367 367
368 std::string ExternalCache::Delegate::GetInstalledExtensionVersion( 368 std::string ExternalCache::Delegate::GetInstalledExtensionVersion(
369 const std::string& id) { 369 const std::string& id) {
370 return std::string(); 370 return std::string();
371 } 371 }
372 372
373 } // namespace chromeos 373 } // namespace chromeos
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698