File: check-osd

package info (click to toggle)
phosh 0.51.0-1
  • links: PTS, VCS
  • area: main
  • in suites: forky
  • size: 9,620 kB
  • sloc: ansic: 81,727; xml: 3,903; python: 502; sh: 456; makefile: 34; lisp: 22; javascript: 6
file content (22 lines) | stat: -rwxr-xr-x 487 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
#!/bin/sh

ICON=audio-volume-medium-symbolic
OUTPUT="HDMI / DisplayPort"

while [ -n "$1" ]; do
    case "$1" in
    -h|--headphone)
	ICON=audio-headphones-symbolic
        ;;
    -n|--no-label)
	OUTPUT=""
        ;;
  esac
  shift
done


gdbus call --session --dest org.gnome.Shell \
                     --object-path /org/gnome/Shell \
                     --method org.gnome.Shell.ShowOSD \
                     '{"icon": <"'${ICON}'">, "label": <"'"${OUTPUT}"'">, "level": <0.5> }'