mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
Also allow Alt+Up/down in the toc edit tool
This commit is contained in:
parent
f95cc11015
commit
b0a721f763
@ -533,10 +533,10 @@ class TreeWidget(QTreeWidget): # {{{
|
|||||||
elif ev.key() == Qt.Key_Right and ev.modifiers() & Qt.CTRL:
|
elif ev.key() == Qt.Key_Right and ev.modifiers() & Qt.CTRL:
|
||||||
self.move_right()
|
self.move_right()
|
||||||
ev.accept()
|
ev.accept()
|
||||||
elif ev.key() == Qt.Key_Up and ev.modifiers() & Qt.CTRL:
|
elif ev.key() == Qt.Key_Up and (ev.modifiers() & Qt.CTRL or ev.modifiers() & Qt.ALT):
|
||||||
self.move_up()
|
self.move_up()
|
||||||
ev.accept()
|
ev.accept()
|
||||||
elif ev.key() == Qt.Key_Down and ev.modifiers() & Qt.CTRL:
|
elif ev.key() == Qt.Key_Down and (ev.modifiers() & Qt.CTRL or ev.modifiers() & Qt.ALT):
|
||||||
self.move_down()
|
self.move_down()
|
||||||
ev.accept()
|
ev.accept()
|
||||||
elif ev.key() in (Qt.Key_Delete, Qt.Key_Backspace):
|
elif ev.key() in (Qt.Key_Delete, Qt.Key_Backspace):
|
||||||
@ -991,6 +991,7 @@ class TOCEditor(QDialog): # {{{
|
|||||||
|
|
||||||
# }}}
|
# }}}
|
||||||
|
|
||||||
|
|
||||||
if __name__ == '__main__':
|
if __name__ == '__main__':
|
||||||
app = Application([], force_calibre_style=True)
|
app = Application([], force_calibre_style=True)
|
||||||
app
|
app
|
||||||
|
Loading…
x
Reference in New Issue
Block a user