diff --git a/ankiqt/ui/facteditor.py b/ankiqt/ui/facteditor.py index 223b97bfe..b1dcc32a8 100644 --- a/ankiqt/ui/facteditor.py +++ b/ankiqt/ui/facteditor.py @@ -999,7 +999,7 @@ class FactEdit(QTextEdit): if (not "japanese" in t and not "mandarin" in t and not "cantonese" in t): - return + return QTextEdit.mouseDoubleClickEvent(self,evt) r = QRegExp("\\{(.*[|,].*)\\}") r.setMinimal(True) @@ -1030,8 +1030,7 @@ class FactEdit(QTextEdit): result = r.indexIn(self.toPlainText(), blockoffset) if found == "": - QTextEdit.mouseDoubleClickEvent(self,evt) - return + return QTextEdit.mouseDoubleClickEvent(self,evt) self.setPlainText(self.toPlainText().replace(result, r.matchedLength(), found)) def focusInEvent(self, evt):