- xrandr >/dev/null # helps enable all screens
-
- # nohup /usr/bin/mplayer \
- # -slave -input file="$fifofile" \
- # -volume "$volume" \
- # "$playuri" >"$statusfile" 2>/dev/null &
-
- # MPlayer2: (statusline on stderr)
- nohup /usr/bin/mplayer \
- --slave --input=file="$fifofile" \
- --volume="$volume" \
- "$playuri" 2>"$statusfile" >/dev/null &
+ xrandr || true >&- # helps enable all screens
+ xvkbd -text '\x+10000\y+10000' || true >&-
+
+ if mplayer |grep -q MPlayer2; then
+ nohup /usr/bin/mplayer \
+ --slave --input=file="$fifofile" \
+ --volume="$volume" \
+ "$playuri" 2>"$statusfile" >&- &
+ else
+ nohup /usr/bin/mplayer \
+ -slave -input file="$fifofile" \
+ -volume "$volume" \
+ "$playuri" >"$statusfile" &
+ fi