summaryrefslogtreecommitdiff
path: root/mate-volume-control/gvc-applet.c
diff options
context:
space:
mode:
authorAndrew Jorgensen <[email protected]>2018-07-09 12:08:21 -0700
committerAndrew Jorgensen <[email protected]>2018-07-09 12:08:21 -0700
commitbe1dbebdba499f579176fc8b58ca44db072ee7f7 (patch)
tree507a45682b122504dd5f231ea2a58a1dbd52e56c /mate-volume-control/gvc-applet.c
parente06fd706690df1fb28548b15697d554b2512b32c (diff)
downloadmate-media-be1dbebdba499f579176fc8b58ca44db072ee7f7.tar.bz2
mate-media-be1dbebdba499f579176fc8b58ca44db072ee7f7.tar.xz
Ignore PulseAudio "monitor" inputs when displaying mic icon
Teradici PCoIP on Linux presently has audio output but no audio input. PulseAudio creates a "monitor" input device for each output device. These combine so that a microphone icon is displayed in the tray even though no actual input device is present. It's misleading, so we created this patch to avoid it.
Diffstat (limited to 'mate-volume-control/gvc-applet.c')
-rw-r--r--mate-volume-control/gvc-applet.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/mate-volume-control/gvc-applet.c b/mate-volume-control/gvc-applet.c
index 686ee11..bcf64a3 100644
--- a/mate-volume-control/gvc-applet.c
+++ b/mate-volume-control/gvc-applet.c
@@ -79,6 +79,14 @@ update_icon_input (GvcApplet *applet)
control = mate_mixer_stream_get_default_control (applet->priv->input);
+ const gchar *stream_name =
+ mate_mixer_stream_get_name (applet->priv->input);
+ g_debug ("Got stream name %s", stream_name);
+ if (g_str_has_suffix (stream_name, ".monitor")) {
+ inputs = NULL;
+ g_debug ("Stream is a monitor, ignoring");
+ }
+
while (inputs != NULL) {
MateMixerStreamControl *input =
MATE_MIXER_STREAM_CONTROL (inputs->data);