op_nubmode: New script that lets you change the nubmode.
[openpandora.oe.git] / recipes / pandora-system / pandora-scripts / op_nubmode.sh
diff --git a/recipes/pandora-system/pandora-scripts/op_nubmode.sh b/recipes/pandora-system/pandora-scripts/op_nubmode.sh
new file mode 100755 (executable)
index 0000000..071a3f3
--- /dev/null
@@ -0,0 +1,13 @@
+#!/bin/bash
+
+if nubl=$(zenity --height=250 --list --title="Select Nub-mode for the left nub" --text="Please select the modus for the left nub.\n\nNote: This can affect running programs.\nSome programs also may change the nub mode themselves."  --column "return" --hide-column=1 --column "Nub Mode" "mouse" "Use the nub as mouse" "scroll" "Use the nub for scrolling" "absolute" "Use the nub as joystick" "mbuttons" "Use the nub as mouse buttons (not implemented yet)") ; then
+
+echo $nubl > /proc/pandora/vsense66
+
+fi
+
+if nubr=$(zenity --height=250 --list --title="Select Nub-mode for the right nub" --text="Please select the modus for the right nub.\n\nNote: This can affect running programs.\nSome programs also may change the nub mode themselves."  --column "return" --hide-column=1 --column "Nub Mode" "mouse" "Use the nub as mouse" "scroll" "Use the nub for scrolling" "absolute" "Use the nub as joystick" "mbuttons" "Use the nub as mouse buttons (not implemented yet)") ; then
+
+echo $nubr > /proc/pandora/vsense67
+
+fi
\ No newline at end of file