UI: Rename MediaState to AlertState
With the inclusion of Bluetooth to the Media State Indicator, the name
"Media State Indicator" becomes a misnomer. This patch makes the enum
"TabMediaState" into an "enum class" named "TabAlertState" and renames the class
"MediaIndicatorButton" to "AlertIndicatorButton".
Since we were there already, this patch also converts the "TabMutedReason" and
"TabMutedResult" into enum classes.
See issue for a summary of the new names.
BUG=598086
Review URL: https://codereview.chromium.org/1827083004
Cr-Commit-Position: refs/heads/master@{#384028}
diff --git a/chrome/browser/extensions/extension_tab_util.cc b/chrome/browser/extensions/extension_tab_util.cc
index 91ca504..ad3c5d4 100644
--- a/chrome/browser/extensions/extension_tab_util.cc
+++ b/chrome/browser/extensions/extension_tab_util.cc
@@ -418,16 +418,16 @@
scoped_ptr<api::tabs::MutedInfo> info(new api::tabs::MutedInfo);
info->muted = contents->IsAudioMuted();
switch (chrome::GetTabAudioMutedReason(contents)) {
- case TAB_MUTED_REASON_NONE:
+ case TabMutedReason::NONE:
break;
- case TAB_MUTED_REASON_CONTEXT_MENU:
- case TAB_MUTED_REASON_AUDIO_INDICATOR:
+ case TabMutedReason::CONTEXT_MENU:
+ case TabMutedReason::AUDIO_INDICATOR:
info->reason = api::tabs::MUTED_INFO_REASON_USER;
break;
- case TAB_MUTED_REASON_MEDIA_CAPTURE:
+ case TabMutedReason::MEDIA_CAPTURE:
info->reason = api::tabs::MUTED_INFO_REASON_CAPTURE;
break;
- case TAB_MUTED_REASON_EXTENSION:
+ case TabMutedReason::EXTENSION:
info->reason = api::tabs::MUTED_INFO_REASON_EXTENSION;
info->extension_id.reset(
new std::string(chrome::GetExtensionIdForMutedTab(contents)));