From 8b050bc561113774f4a7292f805937379e510dab Mon Sep 17 00:00:00 2001 From: Huang Peng Date: Tue, 17 Jun 2008 15:31:10 +0800 Subject: [PATCH] Move modifer masks from keysyms to modifier --- ibus/keysyms.py | 22 ---------------------- ibus/modifier.py | 24 ++++++++++++++++++++++++ 2 files changed, 24 insertions(+), 22 deletions(-) create mode 100644 ibus/modifier.py diff --git a/ibus/keysyms.py b/ibus/keysyms.py index cf6d49c..669088e 100644 --- a/ibus/keysyms.py +++ b/ibus/keysyms.py @@ -19,28 +19,6 @@ # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 # USA -SHIFT_MASK = 1 << 0 -LOCK_MASK = 1 << 1 -CONTROL_MASK = 1 << 2 -ALT_MASK = 1 << 3 -MOD1_MASK = 1 << 3 -MOD2_MASK = 1 << 4 -MOD3_MASK = 1 << 5 -MOD4_MASK = 1 << 6 -MOD5_MASK = 1 << 7 -BUTTON1_MASK = 1 << 8 -BUTTON2_MASK = 1 << 9 -BUTTON3_MASK = 1 << 10 -BUTTON4_MASK = 1 << 11 -BUTTON5_MASK = 1 << 12 - -SUPER_MASK = 1 << 26 -HYPER_MASK = 1 << 27 -META_MASK = 1 << 28 - -RELEASE_MASK = 1 << 30 - -MODIFIER_MASK = 0x5c001fff VoidSymbol = 0xFFFFFF BackSpace = 0xFF08 diff --git a/ibus/modifier.py b/ibus/modifier.py new file mode 100644 index 0000000..12b62cf --- /dev/null +++ b/ibus/modifier.py @@ -0,0 +1,24 @@ + +SHIFT_MASK = 1 << 0 +LOCK_MASK = 1 << 1 +CONTROL_MASK = 1 << 2 +ALT_MASK = 1 << 3 +MOD1_MASK = 1 << 3 +MOD2_MASK = 1 << 4 +MOD3_MASK = 1 << 5 +MOD4_MASK = 1 << 6 +MOD5_MASK = 1 << 7 +BUTTON1_MASK = 1 << 8 +BUTTON2_MASK = 1 << 9 +BUTTON3_MASK = 1 << 10 +BUTTON4_MASK = 1 << 11 +BUTTON5_MASK = 1 << 12 + +SUPER_MASK = 1 << 26 +HYPER_MASK = 1 << 27 +META_MASK = 1 << 28 + +RELEASE_MASK = 1 << 30 + +MODIFIER_MASK = 0x5c001fff + -- 2.7.4