Sophie

Sophie

distrib > Mageia > 5 > x86_64 > media > core-release > by-pkgid > 13f5dcef5358e9d5a2a5a1ae6baf28fc > files > 163

gtkdialog-0.8.3-1.mga5.x86_64.rpm

#!/bin/sh

## Includes.
. funcPreviousNext
. functmpGet

## Automatically play the next track when the player terminates
## (this is called periodically from a timer).

funcAutoNext() {
	if [ -z "$BASH" ]; then local FUNCNAME=funcAutoNext; fi
	if [ $DEBUG_TRANSITS -ne 0 ]; then echo "$FUNCNAME: IN"; fi

	if [ `functmpGet playerstate` = playing ]; then
## 		ps -o s= `functmpGet playerpid` > /dev/null	Redundant: builtin found.
		kill -0 `functmpGet playerpid` 2> /dev/null
		if [ $? -ne 0 ]; then
			funcPreviousNext 1
		fi
	fi

	if [ $DEBUG_TRANSITS -ne 0 ]; then echo "$FUNCNAME: OUT"; fi
}