This commit is contained in:
Kovid Goyal 2011-08-13 10:25:45 -06:00
parent bd48dec0fa
commit 3ffef84a43

View File

@ -452,7 +452,9 @@ class Delegate(QStyledItemDelegate): # {{{
def to_doc(self, index):
data = index.data(Qt.UserRole).toPyObject()
if data.is_shortcut:
if data is None:
html = _('<b>An unknown error occurred</b>')
elif data.is_shortcut:
shortcut = data.data
# Shortcut
keys = [unicode(k.toString(k.NativeText)) for k in shortcut['keys']]