Fixes bug

This commit is contained in:
St.Huang 2018-08-19 12:13:16 +08:00
parent f817763258
commit de1851fc6d
2 changed files with 2 additions and 2 deletions

View File

@ -97,7 +97,7 @@ def customize_addcards():
if e.buttons() & Qt.LeftButton: if e.buttons() & Qt.LeftButton:
menu = QMenu(self) menu = QMenu(self)
menu.addAction(_("Query"), lambda: query_from_editor_all_fields(self.editor), QKeySequence(my_shortcut)) menu.addAction(_("Query"), lambda: query_from_editor_all_fields(self.editor), QKeySequence(my_shortcut))
menu.addAction(_("Options"), lambda: show_options(self)) menu.addAction(_("Options"), lambda: show_options(self, self.editor.note.model()['id']))
menu.exec_(fastwqBtn.mapToGlobal(QPoint(0, fastwqBtn.height()))) menu.exec_(fastwqBtn.mapToGlobal(QPoint(0, fastwqBtn.height())))
else: else:
query_from_editor_all_fields(self.editor) query_from_editor_all_fields(self.editor)

View File

@ -97,7 +97,7 @@ def customize_addcards():
if e.buttons() & Qt.LeftButton: if e.buttons() & Qt.LeftButton:
menu = QMenu(self) menu = QMenu(self)
menu.addAction(_("Query"), lambda: query_from_editor_all_fields(self.editor), QKeySequence(my_shortcut)) menu.addAction(_("Query"), lambda: query_from_editor_all_fields(self.editor), QKeySequence(my_shortcut))
menu.addAction(_("Options"), lambda: show_options(self)) menu.addAction(_("Options"), lambda: show_options(self, self.editor.note.model()['id']))
menu.exec_(fastwqBtn.mapToGlobal(QPoint(0, fastwqBtn.height()))) menu.exec_(fastwqBtn.mapToGlobal(QPoint(0, fastwqBtn.height())))
else: else:
query_from_editor_all_fields(self.editor) query_from_editor_all_fields(self.editor)