Commit 3ecc6a12 authored by kinaba@chromium.org's avatar kinaba@chromium.org

Flip the flag and enable MTP support by default.

The --enable-filemanager-mtp is now on by default.
It can still be disabled by --enable-filemanager-mtp=false, or
choosing "disabled" in about:flags.

BUG=266939

Review URL: https://codereview.chromium.org/314033002

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@275375 0039d316-1c4b-4281-b951-d872f2087c98
parent 5fd9c90f
......@@ -427,6 +427,16 @@ const Experiment::Choice kMalwareInterstitialVersions[] = {
switches::kMalwareInterstitialVersionV3, "" },
};
#if defined(OS_CHROMEOS)
const Experiment::Choice kEnableFileManagerMTPChoices[] = {
{ IDS_GENERIC_EXPERIMENT_CHOICE_DEFAULT, "", "" },
{ IDS_GENERIC_EXPERIMENT_CHOICE_ENABLED,
chromeos::switches::kEnableFileManagerMTP, "true" },
{ IDS_GENERIC_EXPERIMENT_CHOICE_DISABLED,
chromeos::switches::kEnableFileManagerMTP, "false" }
};
#endif
// RECORDING USER METRICS FOR FLAGS:
// -----------------------------------------------------------------------------
// The first line of the experiment is the internal name. If you'd like to
......@@ -1784,7 +1794,7 @@ const Experiment kExperiments[] = {
IDS_FLAGS_ENABLE_FILE_MANAGER_MTP_NAME,
IDS_FLAGS_ENABLE_FILE_MANAGER_MTP_DESCRIPTION,
kOsCrOS,
SINGLE_VALUE_TYPE(chromeos::switches::kEnableFileManagerMTP)
MULTI_VALUE_TYPE(kEnableFileManagerMTPChoices)
},
#endif
// TODO(tyoshino): Remove this temporary flag and command line switch. See
......
......@@ -395,9 +395,10 @@ void VolumeManager::Initialize() {
}
// Subscribe to storage monitor for MTP notifications.
if (CommandLine::ForCurrentProcess()->HasSwitch(
chromeos::switches::kEnableFileManagerMTP) &&
storage_monitor::StorageMonitor::GetInstance()) {
const bool disable_mtp =
CommandLine::ForCurrentProcess()->GetSwitchValueASCII(
chromeos::switches::kEnableFileManagerMTP) == "false";
if (!disable_mtp && storage_monitor::StorageMonitor::GetInstance()) {
storage_monitor::StorageMonitor::GetInstance()->EnsureInitialized(
base::Bind(&VolumeManager::OnStorageMonitorInitialized,
weak_ptr_factory_.GetWeakPtr()));
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment