diff options
author | zelidrag@chromium.org <zelidrag@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-07-29 21:19:36 +0000 |
---|---|---|
committer | zelidrag@chromium.org <zelidrag@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-07-29 21:19:36 +0000 |
commit | 2fc0b31e7c3660d0c241cf99cdec5ae37f051eb1 (patch) | |
tree | b2701fd49b9d9015d46461ac16ec7fbf67ce21f5 | |
parent | 03d6886d6c82a901ea026451772e56bd78e64df0 (diff) | |
download | chromium_src-2fc0b31e7c3660d0c241cf99cdec5ae37f051eb1.zip chromium_src-2fc0b31e7c3660d0c241cf99cdec5ae37f051eb1.tar.gz chromium_src-2fc0b31e7c3660d0c241cf99cdec5ae37f051eb1.tar.bz2 |
Merge 213711 "Fix broken flags when 'Use new audio handler' enabled"
> Fix broken flags when 'Use new audio handler' enabled
>
> Setting this tri-state option to "enabled" would result in "--" being
> appending to the command line, breaking all subsequent flags and making
> tabs open with flag names.
>
> Fix this by always providing a flag for the enabled state, even though
> that flag is unused. We don't just switch this to a single-value flag
> because doing so would require changing the string for the flag
> description and we would not be able to backport the change.
>
> BUG=262975
> TEST=set flag "Use new audio handler" to enabled and add a new more
> flags. Tabs should open normally and not have flag names.
>
> R=pastarmovj@chromium.org
>
> Review URL: https://codereview.chromium.org/20547002
TBR=jamescook@chromium.org
Review URL: https://codereview.chromium.org/21119003
git-svn-id: svn://svn.chromium.org/chrome/branches/1547/src@214219 0039d316-1c4b-4281-b951-d872f2087c98
-rw-r--r-- | ash/ash_switches.cc | 18 | ||||
-rw-r--r-- | ash/ash_switches.h | 4 | ||||
-rw-r--r-- | chrome/browser/about_flags.cc | 6 |
3 files changed, 20 insertions, 8 deletions
diff --git a/ash/ash_switches.cc b/ash/ash_switches.cc index 2e67ee5..b27bc52 100644 --- a/ash/ash_switches.cc +++ b/ash/ash_switches.cc @@ -78,13 +78,12 @@ const char kAshDisableSoftwareMirroring[] = "ash-disable-software-mirroring"; // Disable the notification when a low-power USB charger is connected. const char kAshDisableUsbChargerNotification[] = "ash-disable-usb-charger-notification"; -#endif - -// Extend the status tray volume item to allow the user to choose an audio -// input and output device. -const char kAshEnableAudioDeviceMenu[] = - "ash-enable-audio-device-menu"; +// TODO(jamescook): Remove this unused flag. It exists only to allow the +// "Enable audio device menu" about:flags item to have the tri-state +// default/enabled/disabled UI. +const char kAshEnableAudioDeviceMenu[] = "ash-enable-audio-device-menu"; +#endif // defined(OS_CHROMEOS) // Enable advanced gestures (e.g. for window management). const char kAshEnableAdvancedGestures[] = "ash-enable-advanced-gestures"; @@ -103,6 +102,13 @@ const char kAshEnableImmersiveFullscreen[] = "ash-enable-immersive-fullscreen"; const char kAshEnableMemoryMonitor[] = "ash-enable-memory-monitor"; #endif +#if defined(OS_CHROMEOS) +// TODO(jamescook): Remove this unused flag. It exists only to allow the +// "Enable new audio handler" about:flags item to have the tri-state +// default/enabled/disabled UI. +const char kAshEnableNewAudioHandler[] = "ash-enable-new-audio-handler"; +#endif + // Enables the Oak tree viewer. const char kAshEnableOak[] = "ash-enable-oak"; diff --git a/ash/ash_switches.h b/ash/ash_switches.h index 23eacfc..102e862 100644 --- a/ash/ash_switches.h +++ b/ash/ash_switches.h @@ -38,6 +38,7 @@ ASH_EXPORT extern const char kAshDisableDragAndDropAppListToLauncher[]; #if defined(OS_CHROMEOS) ASH_EXPORT extern const char kAshDisableSoftwareMirroring[]; ASH_EXPORT extern const char kAshDisableUsbChargerNotification[]; +ASH_EXPORT extern const char kAshEnableAudioDeviceMenu[]; #endif ASH_EXPORT extern const char kAshEnableAudioDeviceMenu[]; ASH_EXPORT extern const char kAshEnableAdvancedGestures[]; @@ -47,6 +48,9 @@ ASH_EXPORT extern const char kAshEnableDockedWindows[]; ASH_EXPORT extern const char kAshEnableMemoryMonitor[]; #endif ASH_EXPORT extern const char kAshEnableImmersiveFullscreen[]; +#if defined(OS_CHROMEOS) +ASH_EXPORT extern const char kAshEnableNewAudioHandler[]; +#endif ASH_EXPORT extern const char kAshEnableOak[]; ASH_EXPORT extern const char kAshEnableStickyEdges[]; ASH_EXPORT extern const char kAshEnableTrayDragging[]; diff --git a/chrome/browser/about_flags.cc b/chrome/browser/about_flags.cc index 73c6cbf..b28da94 100644 --- a/chrome/browser/about_flags.cc +++ b/chrome/browser/about_flags.cc @@ -1219,14 +1219,16 @@ const Experiment kExperiments[] = { IDS_FLAGS_ASH_ENABLE_NEW_AUDIO_HANDLER_NAME, IDS_FLAGS_ASH_ENABLE_NEW_AUDIO_HANDLER_DESCRIPTION, kOsCrOS, - ENABLE_DISABLE_VALUE_TYPE("", ash::switches::kAshDisableNewAudioHandler) + ENABLE_DISABLE_VALUE_TYPE(ash::switches::kAshEnableNewAudioHandler, + ash::switches::kAshDisableNewAudioHandler) }, { "ash-audio-device-menu", IDS_FLAGS_ASH_AUDIO_DEVICE_MENU_NAME, IDS_FLAGS_ASH_AUDIO_DEVICE_MENU_DESCRIPTION, kOsCrOS, - SINGLE_VALUE_TYPE(ash::switches::kAshEnableAudioDeviceMenu) + ENABLE_DISABLE_VALUE_TYPE(ash::switches::kAshEnableAudioDeviceMenu, + ash::switches::kAshDisableAudioDeviceMenu) }, { "enable-carrier-switching", |