enigma.eActionMap.getInstance(p)
assert p
- filename = "keymap.xml"
-
+ filename1 = "data/keymap.xml"
+ filename2 = "/usr/share/enigma2/keymap.xml"
+
try:
- source = open(filename)
+ source = open(filename1)
except:
- raise "couldn't open keymap.xml!"
+ source = open(filename2)
+# raise "couldn't open keymap.xml!"
try:
dom = xml.dom.minidom.parse(source)
# try:
flags = sum(map(flag_ascii_to_id, flags))
- print "-> " + str(flags)
+# print "-> " + str(flags)
# except:
# raise str("%s: illegal flags '%s' specificed in context %s, id '%s'" % (filename, flags, context, id))
except:
raise "key id '" + str(id) + "' is illegal"
- print context + "::" + mapto + " -> " + device + "." + hex(keyid)
+# print context + "::" + mapto + " -> " + device + "." + hex(keyid)
p.bindKey(device, keyid, flags, context, mapto)
parseKeys("generic", cmap)