From fb2d518a30ac0f22471dc2b409f840b3aeb23299 Mon Sep 17 00:00:00 2001 From: Geoffroy Van Cutsem Date: Mon, 8 Oct 2012 17:55:59 +0200 Subject: Add function ('Button2') to skip to next video on the list Change-Id: I87cd2f40992c18ced7754dd073ced98bad0e8317 --- packaging/rundemo.sh | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'packaging') diff --git a/packaging/rundemo.sh b/packaging/rundemo.sh index 0de2a05..cd8c50c 100644 --- a/packaging/rundemo.sh +++ b/packaging/rundemo.sh @@ -49,7 +49,11 @@ case ${BUTTONVALUE} in ;; "Button2") #Run script 2 here - echo "Button 2 script!" + echo "Skipping to the next video" + VIDEO_SCRIPT_PID=$[ $(pgrep -f $VIDEO_SCRIPT_NAME) ] + if [ $VIDEO_SCRIPT_PID != "0" ]; then + pkill -P $VIDEO_SCRIPT_PID gst-launch + fi ;; "Button3") #Run script 3 here -- cgit v1.2.3