diff options
author | Denys Dmytriyenko <denis@denix.org> | 2009-03-17 14:32:59 -0400 |
---|---|---|
committer | Denys Dmytriyenko <denis@denix.org> | 2009-03-17 14:32:59 -0400 |
commit | 709c4d66e0b107ca606941b988bad717c0b45d9b (patch) | |
tree | 37ee08b1eb308f3b2b6426d5793545c38396b838 /recipes/xqtlauncher/xqtlauncher/xqtlauncher | |
parent | fa6cd5a3b993f16c27de4ff82b42684516d433ba (diff) | |
download | openembedded-709c4d66e0b107ca606941b988bad717c0b45d9b.tar.gz |
rename packages/ to recipes/ per earlier agreement
See links below for more details:
http://thread.gmane.org/gmane.comp.handhelds.openembedded/21326
http://thread.gmane.org/gmane.comp.handhelds.openembedded/21816
Signed-off-by: Denys Dmytriyenko <denis@denix.org>
Acked-by: Mike Westerhof <mwester@dls.net>
Acked-by: Philip Balister <philip@balister.org>
Acked-by: Khem Raj <raj.khem@gmail.com>
Acked-by: Marcin Juszkiewicz <hrw@openembedded.org>
Acked-by: Koen Kooi <koen@openembedded.org>
Acked-by: Frans Meulenbroeks <fransmeulenbroeks@gmail.com>
Diffstat (limited to 'recipes/xqtlauncher/xqtlauncher/xqtlauncher')
-rw-r--r-- | recipes/xqtlauncher/xqtlauncher/xqtlauncher | 45 |
1 files changed, 45 insertions, 0 deletions
diff --git a/recipes/xqtlauncher/xqtlauncher/xqtlauncher b/recipes/xqtlauncher/xqtlauncher/xqtlauncher new file mode 100644 index 0000000000..4f2c9f937c --- /dev/null +++ b/recipes/xqtlauncher/xqtlauncher/xqtlauncher @@ -0,0 +1,45 @@ +#set DISPLAY +export DISPLAY=:0.0 +#check if the application is installed +if which $1 ; then + echo start $1 + #is Xqt running? + if test ! -f /var/run/Xqt ;then + #start Xqt + startxqt-wrapper + fi + #do we have atomate access? FIXME: make a function out of this and loop it + if test -f /var/lock/xqtlauncher; then + qcop QPE/TaskBar "message(QString)" "Was not able to lock access. Try again or remove /var/lock/xqtlauncher" + else + #lock access + touch /var/lock/xqtlauncher + if test -f /var/run/xqtlauncher; then + #atomate write nuber of applications running in xqt +1 + echo $(($(cat /var/run/xqtlauncher ) + 1)) > /var/run/xqtlauncher + else + echo 1 > /var/run/xqtlauncher + fi + #remove lock + rm /var/lock/xqtlauncher + #start application + $1 + #do we have atomate access? FIXME: make a function out of this and loop it + if test -f /var/lock/xqtlauncher; then + qcop QPE/TaskBar "message(QString)" "Was not able to lock access. Try again or remove /var/lock/xqtlauncher" + else + #lock access + touch /var/lock/xqtlauncher + COUNTXQT=$(($(cat /var/run/xqtlauncher ) -1)) + echo $COUNTXQT > /var/run/xqtlauncher + if [ $COUNTXQT -le 0 ] ; then + #kill Xqt if there is no application running. + killall Xqt + fi + #remove lock + rm /var/lock/xqtlauncher + fi + fi +else + qcop QPE/TaskBar "message(QString)" "Application not found" +fi |