matchbox-session-sato: use SHOWCURSOR from environment

Instead of using a SHOWCURSOR variable hardcoded from the
HAVE_TOUCHSCREEN environment var, allow to set it freely in formfactors
config file and use it to show (or not) the cursor in the graphic
session.

Signed-off-by: Javier Viguera <javier.viguera@digi.com>
This commit is contained in:
Javier Viguera 2014-01-08 14:05:58 +01:00
parent 9dd8939196
commit fc5de6c6b4
3 changed files with 34 additions and 0 deletions

View File

@ -1,3 +1,4 @@
# Display options # Display options
HAVE_TOUCHSCREEN=1 HAVE_TOUCHSCREEN=1
HAVE_KEYBOARD=0 HAVE_KEYBOARD=0
SHOWCURSOR="yes"

View File

@ -0,0 +1,30 @@
#!/bin/sh
. /etc/formfactor/config
## Use SHOWCURSOR from formfactor config files instaed of hardcoding it
# if [ "$HAVE_TOUCHSCREEN" = "1" ]; then
# SHOWCURSOR="no"
# else
# SHOWCURSOR="yes"
# fi
if [ "$HAVE_KEYBOARD" = "1" ]; then
KEYBOARD_APPLET=""
else
KEYBOARD_APPLET="keyboard"
fi
matchbox-desktop &
# Lines containing feature-[foo] are removed at build time if the machine
# doesn't have the feature "foo".
START_APPLETS=showdesktop,windowselector
END_APPLETS=clock,battery,$KEYBOARD_APPLET,systray,startup-notify,notify
END_APPLETS=openmoko-panel-gsm,$END_APPLETS # feature-phone
matchbox-panel --titlebar --start-applets $START_APPLETS --end-applets $END_APPLETS &
exec matchbox-window-manager -theme Sato -use_desktop_mode decorated -use_cursor $SHOWCURSOR $@

View File

@ -0,0 +1,3 @@
# Copyright (C) 2014 Digi International.
FILESEXTRAPATHS_prepend := "${THISDIR}/${PN}:"