diff options
| author | Felix Domke <tmbinc@elitedvb.net> | 2005-11-18 04:53:43 +0000 |
|---|---|---|
| committer | Felix Domke <tmbinc@elitedvb.net> | 2005-11-18 04:53:43 +0000 |
| commit | f7c13b8fcc4373f972387a0e7928658b818392b9 (patch) | |
| tree | c34b3a5aab455bdb0f660dfa840285c622a9000d /lib/python/Tools | |
| parent | d2b1dcb3466ed5476094d9ff445d1df1b4ed14ff (diff) | |
| download | enigma2-f7c13b8fcc4373f972387a0e7928658b818392b9.tar.gz enigma2-f7c13b8fcc4373f972387a0e7928658b818392b9.zip | |
helplist: keys are not anymore secret, at least not for us professionals. skin fixed a bit. (discrete) standby added to help.
Diffstat (limited to 'lib/python/Tools')
| -rw-r--r-- | lib/python/Tools/KeyBindings.py | 17 | ||||
| -rw-r--r-- | lib/python/Tools/__init__.py | 2 |
2 files changed, 18 insertions, 1 deletions
diff --git a/lib/python/Tools/KeyBindings.py b/lib/python/Tools/KeyBindings.py new file mode 100644 index 00000000..b55e3555 --- /dev/null +++ b/lib/python/Tools/KeyBindings.py @@ -0,0 +1,17 @@ + +keyBindings = { } + +def addKeyBinding(key, context, action): + if (context, action) in keyBindings: + keyBindings[(context, action)].append(key) + else: + keyBindings[(context, action)] = [key] + +def queryKeyBinding(context, action): + if (context, action) in keyBindings: + return keyBindings[(context, action)] + else: + return [ ] + +def getKeyDescription(key): + return "key_%0x" % key diff --git a/lib/python/Tools/__init__.py b/lib/python/Tools/__init__.py index 72a1abb7..d8e646d0 100644 --- a/lib/python/Tools/__init__.py +++ b/lib/python/Tools/__init__.py @@ -1 +1 @@ -all = ["FuzzyDate.py", "XMLTools.py", "Directories.py"] +all = ["FuzzyDate.py", "XMLTools.py", "Directories.py", "KeyBindings.py"] |
