PageRenderTime 102ms CodeModel.GetById 18ms RepoModel.GetById 3ms app.codeStats 0ms

/python/scim/KeyMask.py

http://scim-python.googlecode.com/
Python | 48 lines | 19 code | 4 blank | 25 comment | 0 complexity | 25b12e1c93d0e35c23f26500c0c0f9ce MD5 | raw file
  1. # -*- coding: utf-8 -*-
  2. # vim:set noet ts=4:
  3. #
  4. # scim-python
  5. #
  6. # Copyright (c) 2007-2008 Huang Peng <shawn.p.huang@gmail.com>
  7. #
  8. #
  9. # This library is free software; you can redistribute it and/or
  10. # modify it under the terms of the GNU Lesser General Public
  11. # License as published by the Free Software Foundation; either
  12. # version 2 of the License, or (at your option) any later version.
  13. #
  14. # This library is distributed in the hope that it will be useful,
  15. # but WITHOUT ANY WARRANTY; without even the implied warranty of
  16. # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  17. # GNU Lesser General Public License for more details.
  18. #
  19. # You should have received a copy of the GNU Lesser General Public
  20. # License along with this program; if not, write to the
  21. # Free Software Foundation, Inc., 59 Temple Place, Suite 330,
  22. # Boston, MA 02111-1307 USA
  23. #
  24. # $Id: $
  25. #
  26. NullMask = 0
  27. ShiftMask = (1<<0)
  28. CapsLockMask = (1<<1)
  29. ControlMask = (1<<2)
  30. AltMask = (1<<3)
  31. MetaMask = (1<<4)
  32. SuperMask = (1<<5)
  33. HyperMask = (1<<6)
  34. NumLockMask = (1<<7)
  35. LockMask = CapsLockMask
  36. Mod1Mask = AltMask
  37. Mod2Mask = MetaMask
  38. Mod3Mask = SuperMask
  39. Mod4Mask = HyperMask
  40. Mod5Mask = NumLockMask
  41. ScrollLockMask = 0
  42. QuirkKanaRoMask= (1<<14)
  43. ReleaseMask = (1<<15)
  44. AllMasks = 0xC0FF