Show mic volume on statusbar.
This commit is contained in:
parent
07bcbdd8d3
commit
4a351c4cd6
1 changed files with 4 additions and 4 deletions
|
@ -17,12 +17,12 @@ else
|
||||||
volmute=$(pactl get-sink-mute @DEFAULT_SINK@ | awk -F': ' '{print $2}')
|
volmute=$(pactl get-sink-mute @DEFAULT_SINK@ | awk -F': ' '{print $2}')
|
||||||
micmute=$(pactl get-source-mute @DEFAULT_SOURCE@ | awk -F': ' '{print $2}')
|
micmute=$(pactl get-source-mute @DEFAULT_SOURCE@ | awk -F': ' '{print $2}')
|
||||||
if [ "$volmute" = yes ] && [ "$micmute" = yes ]; then
|
if [ "$volmute" = yes ] && [ "$micmute" = yes ]; then
|
||||||
printf "^c#161616^^b#fd4285^mute \ue02b mute \ue04f^d^"
|
printf "^c#161616^^b#fd4285^\ue02b mute \ue04f mute^d^"
|
||||||
elif [ "$vol" -eq 0 ] && [ "$mic" -eq 0 ]; then
|
elif [ "$vol" -eq 0 ] && [ "$mic" -eq 0 ]; then
|
||||||
printf "^c#161616^^b#fd4285^mute \ue02b mute \ue04f^d^"
|
printf "^c#161616^^b#fd4285^\ue02b mute \ue04f mute^d^"
|
||||||
else
|
else
|
||||||
[ $(pactl get-sink-mute @DEFAULT_SINK@ | awk -F': ' '{print $2}') = yes ] || [ "$vol" -eq 0 ] && volinfo="^c#161616^^b#fd4285^mute \ue04f^d^" || volinfo="${vol}%% \ue050"
|
[ $(pactl get-sink-mute @DEFAULT_SINK@ | awk -F': ' '{print $2}') = yes ] || [ "$vol" -eq 0 ] && volinfo="^c#161616^^b#fd4285^\ue04f mute^d^" || volinfo="\ue050 ${vol}%%"
|
||||||
[ $(pactl get-source-mute @DEFAULT_SOURCE@ | awk -F': ' '{print $2}') = yes ] || [ "$mic" -eq 0 ] && micinfo="^c#161616^^b#fd4285^\ue02b mute^d^" || micinfo="${mic}%% \ue029"
|
[ $(pactl get-source-mute @DEFAULT_SOURCE@ | awk -F': ' '{print $2}') = yes ] || [ "$mic" -eq 0 ] && micinfo="^c#161616^^b#fd4285^\ue02b mute^d^" || micinfo="\ue029 ${mic}%%"
|
||||||
printf "${micinfo} ${volinfo}"
|
printf "${micinfo} ${volinfo}"
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue