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

Unified Diff: components/storage_monitor/media_storage_util.cc

Issue 2834703003: Remove unmapped media galleries histograms. (Closed)
Patch Set: Created 3 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 side-by-side diff with in-line comments
Download patch
Index: components/storage_monitor/media_storage_util.cc
diff --git a/components/storage_monitor/media_storage_util.cc b/components/storage_monitor/media_storage_util.cc
index 5dbfdcc083ebeff078f2d82083091ac797f60817..7841e4e294e339e965767b6b3afc0df80a988e6f 100644
--- a/components/storage_monitor/media_storage_util.cc
+++ b/components/storage_monitor/media_storage_util.cc
@@ -9,7 +9,6 @@
#include "base/callback.h"
#include "base/files/file_util.h"
#include "base/logging.h"
-#include "base/metrics/histogram_macros.h"
#include "base/strings/string_util.h"
#include "base/strings/utf_string_conversions.h"
#include "build/build_config.h"
@@ -23,19 +22,6 @@ namespace storage_monitor {
namespace {
-// MediaDeviceNotification.DeviceInfo histogram values.
-enum DeviceInfoHistogramBuckets {
- MASS_STORAGE_DEVICE_NAME_AND_UUID_AVAILABLE,
- MASS_STORAGE_DEVICE_UUID_MISSING,
- MASS_STORAGE_DEVICE_NAME_MISSING,
- MASS_STORAGE_DEVICE_NAME_AND_UUID_MISSING,
- MTP_STORAGE_DEVICE_NAME_AND_UUID_AVAILABLE,
- MTP_STORAGE_DEVICE_UUID_MISSING,
- MTP_STORAGE_DEVICE_NAME_MISSING,
- MTP_STORAGE_DEVICE_NAME_AND_UUID_MISSING,
- DEVICE_INFO_BUCKET_BOUNDARY
-};
-
#if !defined(OS_WIN)
const char kRootPath[] = "/";
#endif
@@ -213,30 +199,6 @@ base::FilePath MediaStorageUtil::FindDevicePathById(
}
// static
-void MediaStorageUtil::RecordDeviceInfoHistogram(
- bool mass_storage,
- const std::string& device_uuid,
- const base::string16& device_label) {
- unsigned int event_number = 0;
- if (!mass_storage)
- event_number = 4;
-
- if (device_label.empty())
- event_number += 2;
-
- if (device_uuid.empty())
- event_number += 1;
- enum DeviceInfoHistogramBuckets event =
- static_cast<enum DeviceInfoHistogramBuckets>(event_number);
- if (event >= DEVICE_INFO_BUCKET_BOUNDARY) {
- NOTREACHED();
- return;
- }
- UMA_HISTOGRAM_ENUMERATION("MediaDeviceNotifications.DeviceInfo", event,
- DEVICE_INFO_BUCKET_BOUNDARY);
-}
-
-// static
bool MediaStorageUtil::IsRemovableStorageAttached(const std::string& id) {
StorageMonitor* monitor = StorageMonitor::GetInstance();
if (!monitor)

Powered by Google App Engine
This is Rietveld 408576698