summaryrefslogtreecommitdiff
path: root/packages/zaurusd/files/zaurus-hinge.matchbox-landscape
diff options
context:
space:
mode:
authorMatthias Hentges <oe@hentges.net>2006-06-06 07:17:31 +0000
committerOpenEmbedded Project <openembedded-devel@lists.openembedded.org>2006-06-06 07:17:31 +0000
commit20ed81ad19f90b75b2f8371d1e8dd333c420f61d (patch)
tree0ce2d6787ff0f95dbc8008c9c3a2ec60de6f5c7a /packages/zaurusd/files/zaurus-hinge.matchbox-landscape
parent9173bc6eb7cf9ddb1231b770106418fa06bea799 (diff)
zaurusd: Make zaurus-hinge easier to use by external programs
Diffstat (limited to 'packages/zaurusd/files/zaurus-hinge.matchbox-landscape')
-rw-r--r--packages/zaurusd/files/zaurus-hinge.matchbox-landscape21
1 files changed, 21 insertions, 0 deletions
diff --git a/packages/zaurusd/files/zaurus-hinge.matchbox-landscape b/packages/zaurusd/files/zaurus-hinge.matchbox-landscape
new file mode 100644
index 0000000000..e7b92b5140
--- /dev/null
+++ b/packages/zaurusd/files/zaurus-hinge.matchbox-landscape
@@ -0,0 +1,21 @@
+ #!/bin/sh
+
+ # As matchbox-panel updates its written configuration right after an applet dies / is killed, we can not be sure
+ # whether the user had gpe-panel in his preferences after rotating to portrait. And since there is a slim chance
+ # that a user changes his preferences from time to time, we renew that dumped configuration every now and then ;)
+
+ if ! test -e "/tmp/gpe-panel.session-$panel_user"
+ then
+ test -e /home/$panel_user/.matchbox/mbdock.session && cp /home/$panel_user/.matchbox/mbdock.session "/tmp/gpe-panel.session-$panel_user"
+ test -e "/tmp/gpe-panel.session-$panel_user" && cat "/tmp/gpe-panel.session-$panel_user" | grep -q panel || killproc ${ZD_BINDIR}/mbinputmgr
+ else
+ cat "/tmp/gpe-panel.session-$panel_user" | grep -q panel || killproc ${ZD_BINDIR}/mbinputmgr
+ rm "/tmp/gpe-panel.session-$panel_user"
+ fi
+
+ # urg mbinputmgr should kill below
+ killproc ${ZD_BINDIR}/matchbox-keyboard
+ killproc ${ZD_BINDIR}/matchbox-stroke
+ if [ -x ${ZD_BINDIR}/xrandr ]; then
+ xrandr -o normal
+ fi