Advertisement
Guest User

:3

a guest
Nov 1st, 2014
164
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. import keycapture,keypress
  2. key=None
  3. status=0
  4. def onoff():
  5.     global key
  6.     if key:
  7.         if status:
  8.           key.keys=()
  9.  
  10.           key.stop()
  11.           key.start()
  12.        if not status:
  13.            key.keys=codes
  14.            key.stop()
  15.            key.start()
  16. def handleKey(code):
  17.     if kode=='EStdKeyFullStop':
  18.         keypress.simulate_key('EStdKeyLeftShift',1)
  19. codes=('tombol untuk on/of','EStdKeyFullStop')
  20. key=keycapture.KeyCapturer(handleKey)
  21. key.keys=('kode tombol untuk on/off',)
  22. key.start()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement