Lines Matching refs:disk
37 // Emulates to add new disk physically (e.g., connecting a
44 Disk* disk = in_disk.get();
45 bool new_disk = InsertDisk(disk->device_path(), in_disk.Pass());
48 OnDiskEvent(new_disk ? DISK_ADDED : DISK_CHANGED, disk));
51 // Emulates to remove a disk phyically (e.g., removing a USB flash from
54 scoped_ptr<Disk> disk(RemoveDisk(source_path));
55 if (disk.get()) {
57 Observer, observers_, OnDiskEvent(DISK_REMOVED, disk.get()));
96 virtual bool AddDiskForTest(Disk* disk) OVERRIDE { return false; }
103 bool InsertDisk(const std::string& path, scoped_ptr<Disk> disk) {
110 insert_result.first->second = disk.release(); // Moves ownership.
133 std::string* out_path, const disks::DiskMountManager::Disk& disk) {
134 *out_path = disk.device_path();