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

Unified Diff: chrome/browser/chromeos/extensions/file_manager/device_event_router.cc

Issue 490643005: Files.app: Start to use DeviceEventRouter. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebased. Created 6 years, 4 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/chromeos/extensions/file_manager/device_event_router.cc
diff --git a/chrome/browser/chromeos/extensions/file_manager/device_event_router.cc b/chrome/browser/chromeos/extensions/file_manager/device_event_router.cc
index 9514d5d52e0515b752e099dfd2861d1c9e441d85..5c01fc02550c019b9f0dd8e2ec682a60dd71521e 100644
--- a/chrome/browser/chromeos/extensions/file_manager/device_event_router.cc
+++ b/chrome/browser/chromeos/extensions/file_manager/device_event_router.cc
@@ -77,9 +77,8 @@ void DeviceEventRouter::OnDeviceAddedDelayed(const std::string& device_path) {
DCHECK(thread_checker_.CalledOnValidThread());
if (GetDeviceState(device_path) == DEVICE_SCANNED) {
- // TODO(hirono): Rename DEVICE_EVENT_TYPE_ADDED with
- // DEVICE_EVENT_TYPE_SCAN_STARTED.
- OnDeviceEvent(file_browser_private::DEVICE_EVENT_TYPE_ADDED, device_path);
+ OnDeviceEvent(file_browser_private::DEVICE_EVENT_TYPE_SCAN_STARTED,
+ device_path);
SetDeviceState(device_path, DEVICE_SCANNED_AND_REPORTED);
}
}
@@ -99,7 +98,7 @@ void DeviceEventRouter::OnDiskAdded(
// If the disk is not being mounted, mark the device scan cancelled.
const std::string& device_path = disk.system_path_prefix();
if (GetDeviceState(device_path) == DEVICE_SCANNED_AND_REPORTED) {
- OnDeviceEvent(file_browser_private::DEVICE_EVENT_TYPE_SCAN_CANCELED,
+ OnDeviceEvent(file_browser_private::DEVICE_EVENT_TYPE_SCAN_CANCELLED,
device_path);
}
SetDeviceState(device_path, DEVICE_STATE_USUAL);
@@ -159,9 +158,6 @@ void DeviceEventRouter::OnFormatCompleted(const std::string& device_path,
device_path);
}
-void DeviceEventRouter::OnHardUnplugged(const std::string& device_path) {
-}
-
void DeviceEventRouter::SuspendImminent() {
DCHECK(thread_checker_.CalledOnValidThread());
is_resuming_ = true;

Powered by Google App Engine
This is Rietveld 408576698