#!/bin/bash #--------------------------------------------------------------------- # File information. # File: gnash-launcher.wrapper.in # Purpose: Single-instance wrapper (Laclin-specific) # License: BSD-style (for this file only) #--------------------------------------------------------------------- # Wrapper parameters. BASEDIR=$PRODTREE/gnash XBINDIR=$BASEDIR/bin TARGET=$XBINDIR/gtk-gnash LIBDIR=$BASEDIR/lib PROGNAME="gtk-gnash" SNDFLAG=true #--------------------------------------------------------------------- # Run the target if it's available. if [ -f $TARGET ]; then # If there are no parameters, start in # user's home directory if [ "x$1" = "x" ]; then cd; fi if [ "@$SNDFLAG" == "@true" ]; then resetpcmvol # Adjust volume # resetpulse fi if [ -d $LIBDIR ]; then # Adjust LD_LIBRARY_PATH LD_LIBRARY_PATH=$LIBDIR:$LD_LIBRARY_PATH export LD_LIBRARY_PATH fi PATH=$XBINDIR:$PATH # Adjust PATH FILE=$1 if [ "@$FILE" \!= "@" ]; then NFILE=$PRODTREE/gnash/samples/$FILE if [ -f $NFILE ]; then FILE=$NFILE; fi fi padsp /laclin/lacutil/single-instance --wait --usepid \ "gtk-gnash\b" \ $TARGET -X 500 -Y 125 --scale 1.50 -1 $FILE & # $TARGET -X 300 -Y 75 --scale 1.25 -1 $FILE & exit fi #--------------------------------------------------------------------- # Display a missing-program dialog. TITLE="$PROGNAME isn't installed" /laclin/lacutil/single-instance \ --wait --usewin "^$TITLE" \ zenity --error --no-wrap --title="$TITLE" --text="$TITLE"