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

Unified Diff: chrome/browser/ui/views/tabs/browser_tab_strip_controller.cc

Issue 591963002: Tab audio mute control (views UI), behind a switch (off by default). (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase + add about:flags experiment Created 6 years, 3 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/ui/views/tabs/browser_tab_strip_controller.cc
diff --git a/chrome/browser/ui/views/tabs/browser_tab_strip_controller.cc b/chrome/browser/ui/views/tabs/browser_tab_strip_controller.cc
index ec84d5f045a1f968469a9db0473a98867b61dc52..3f1786ad38e385eb04d2197599be1bd75a147421 100644
--- a/chrome/browser/ui/views/tabs/browser_tab_strip_controller.cc
+++ b/chrome/browser/ui/views/tabs/browser_tab_strip_controller.cc
@@ -300,6 +300,11 @@ void BrowserTabStripController::CloseTab(int model_index,
TabStripModel::CLOSE_CREATE_HISTORICAL_TAB);
}
+void BrowserTabStripController::ToggleTabAudioMute(int model_index) {
+ content::WebContents* const contents = model_->GetWebContentsAt(model_index);
+ chrome::SetTabAudioMuted(contents, !chrome::IsTabAudioMuted(contents));
+}
+
void BrowserTabStripController::ShowContextMenuForTab(
Tab* tab,
const gfx::Point& p,

Powered by Google App Engine
This is Rietveld 408576698