mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
Merge from trunk
This commit is contained in:
commit
6b088aceda
@ -53,6 +53,7 @@ def finalize(shortcuts, custom_keys_map={}): # {{{
|
|||||||
if DEBUG:
|
if DEBUG:
|
||||||
prints('Key %r for shortcut %s is already used by'
|
prints('Key %r for shortcut %s is already used by'
|
||||||
' %s, ignoring'%(x, shortcut['name'], seen[x]['name']))
|
' %s, ignoring'%(x, shortcut['name'], seen[x]['name']))
|
||||||
|
keys_map[unique_name] = ()
|
||||||
continue
|
continue
|
||||||
seen[x] = shortcut
|
seen[x] = shortcut
|
||||||
keys.append(ks)
|
keys.append(ks)
|
||||||
@ -149,7 +150,7 @@ class ConfigModel(QAbstractItemModel, SearchQueryParser):
|
|||||||
shortcut_map = {k:v.copy() for k, v in
|
shortcut_map = {k:v.copy() for k, v in
|
||||||
self.keyboard.shortcuts.iteritems()}
|
self.keyboard.shortcuts.iteritems()}
|
||||||
for un, s in shortcut_map.iteritems():
|
for un, s in shortcut_map.iteritems():
|
||||||
s['keys'] = tuple(self.keyboard.keys_map[un])
|
s['keys'] = tuple(self.keyboard.keys_map.get(un, ()))
|
||||||
s['unique_name'] = un
|
s['unique_name'] = un
|
||||||
s['group'] = [g for g, names in self.keyboard.groups.iteritems() if un in
|
s['group'] = [g for g, names in self.keyboard.groups.iteritems() if un in
|
||||||
names][0]
|
names][0]
|
||||||
|
Loading…
x
Reference in New Issue
Block a user