diff options
author | BuildTools <paul.wachendorf@web.de> | 2015-12-09 23:10:11 +0300 |
---|---|---|
committer | BuildTools <paul.wachendorf@web.de> | 2015-12-09 23:10:11 +0300 |
commit | 2342e9dc5c55c3c7b2e2909f39c7d31bf4eaf12c (patch) | |
tree | acff0fb7a85efcc3a729281f06c7f373bd3ed2b4 /scripts | |
parent | 5008552221978260eab1611801f2cc94ffb95c8f (diff) |
added setStickPressedCallback and actalized example script
Diffstat (limited to 'scripts')
-rw-r--r-- | scripts/sc-callbacks.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/scripts/sc-callbacks.py b/scripts/sc-callbacks.py index 7482faa..042df21 100644 --- a/scripts/sc-callbacks.py +++ b/scripts/sc-callbacks.py @@ -43,6 +43,9 @@ def touchpad_click_callback(evm, pad, pressed): def touchpad_touch_callback(evm, pad, x, y): print "Tochpad {} was touched @{},{}".format(pad, x, y) +def stick_pressed_callback(evm): + print "Stick pressed" + def evminit(): evm = EventMapper() evm.setButtonCallback(SCButtons.STEAM, button_pressed_callback) @@ -60,6 +63,7 @@ def evminit(): evm.setButtonCallback(SCButtons.BACK, button_pressed_callback) evm.setPadButtonCallback(Pos.LEFT, touchpad_touch_callback) evm.setPadButtonCallback(Pos.RIGHT, touchpad_click_callback, clicked=True) + evm.setStickPressedCallback(stick_pressed_callback) return evm |