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

Side by Side Diff: chrome/browser/chromeos/file_manager/volume_manager.h

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: 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 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 #ifndef CHROME_BROWSER_CHROMEOS_FILE_MANAGER_VOLUME_MANAGER_H_ 5 #ifndef CHROME_BROWSER_CHROMEOS_FILE_MANAGER_VOLUME_MANAGER_H_
6 #define CHROME_BROWSER_CHROMEOS_FILE_MANAGER_VOLUME_MANAGER_H_ 6 #define CHROME_BROWSER_CHROMEOS_FILE_MANAGER_VOLUME_MANAGER_H_
7 7
8 #include <map> 8 #include <map>
9 #include <memory>
9 #include <string> 10 #include <string>
10 #include <vector> 11 #include <vector>
11 12
12 #include "base/callback.h" 13 #include "base/callback.h"
13 #include "base/files/file.h" 14 #include "base/files/file.h"
14 #include "base/files/file_path.h" 15 #include "base/files/file_path.h"
15 #include "base/macros.h" 16 #include "base/macros.h"
16 #include "base/memory/linked_ptr.h" 17 #include "base/memory/linked_ptr.h"
17 #include "base/memory/scoped_ptr.h"
18 #include "base/memory/weak_ptr.h" 18 #include "base/memory/weak_ptr.h"
19 #include "base/observer_list.h" 19 #include "base/observer_list.h"
20 #include "chrome/browser/chromeos/drive/drive_integration_service.h" 20 #include "chrome/browser/chromeos/drive/drive_integration_service.h"
21 #include "chrome/browser/chromeos/file_system_provider/observer.h" 21 #include "chrome/browser/chromeos/file_system_provider/observer.h"
22 #include "chrome/browser/chromeos/file_system_provider/service.h" 22 #include "chrome/browser/chromeos/file_system_provider/service.h"
23 #include "chromeos/dbus/cros_disks_client.h" 23 #include "chromeos/dbus/cros_disks_client.h"
24 #include "chromeos/disks/disk_mount_manager.h" 24 #include "chromeos/disks/disk_mount_manager.h"
25 #include "components/keyed_service/core/keyed_service.h" 25 #include "components/keyed_service/core/keyed_service.h"
26 #include "components/prefs/pref_change_registrar.h" 26 #include "components/prefs/pref_change_registrar.h"
27 #include "components/storage_monitor/removable_storage_observer.h" 27 #include "components/storage_monitor/removable_storage_observer.h"
(...skipping 276 matching lines...) Expand 10 before | Expand all | Expand 10 after
304 304
305 Profile* profile_; 305 Profile* profile_;
306 drive::DriveIntegrationService* drive_integration_service_; // Not owned. 306 drive::DriveIntegrationService* drive_integration_service_; // Not owned.
307 chromeos::disks::DiskMountManager* disk_mount_manager_; // Not owned. 307 chromeos::disks::DiskMountManager* disk_mount_manager_; // Not owned.
308 PrefChangeRegistrar pref_change_registrar_; 308 PrefChangeRegistrar pref_change_registrar_;
309 base::ObserverList<VolumeManagerObserver> observers_; 309 base::ObserverList<VolumeManagerObserver> observers_;
310 chromeos::file_system_provider::Service* 310 chromeos::file_system_provider::Service*
311 file_system_provider_service_; // Not owned by this class. 311 file_system_provider_service_; // Not owned by this class.
312 GetMtpStorageInfoCallback get_mtp_storage_info_callback_; 312 GetMtpStorageInfoCallback get_mtp_storage_info_callback_;
313 std::map<std::string, linked_ptr<Volume>> mounted_volumes_; 313 std::map<std::string, linked_ptr<Volume>> mounted_volumes_;
314 scoped_ptr<SnapshotManager> snapshot_manager_; 314 std::unique_ptr<SnapshotManager> snapshot_manager_;
315 315
316 // Note: This should remain the last member so it'll be destroyed and 316 // Note: This should remain the last member so it'll be destroyed and
317 // invalidate its weak pointers before any other members are destroyed. 317 // invalidate its weak pointers before any other members are destroyed.
318 base::WeakPtrFactory<VolumeManager> weak_ptr_factory_; 318 base::WeakPtrFactory<VolumeManager> weak_ptr_factory_;
319 DISALLOW_COPY_AND_ASSIGN(VolumeManager); 319 DISALLOW_COPY_AND_ASSIGN(VolumeManager);
320 }; 320 };
321 321
322 } // namespace file_manager 322 } // namespace file_manager
323 323
324 #endif // CHROME_BROWSER_CHROMEOS_FILE_MANAGER_VOLUME_MANAGER_H_ 324 #endif // CHROME_BROWSER_CHROMEOS_FILE_MANAGER_VOLUME_MANAGER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698