Edit book: Fix double clicking in the see what changed dialog not opening the file in the editor since calibre 6.0

PyQt6's enums strike again
This commit is contained in:
Kovid Goyal 2022-10-30 08:55:31 +05:30
parent 57a3641e54
commit 73637baaa9
No known key found for this signature in database
GPG Key ID: 06BC317B515ACE7C

View File

@ -179,7 +179,7 @@ class TextBrowser(PlainTextEdit): # {{{
m.exec(self.mapToGlobal(pos))
def mouseDoubleClickEvent(self, ev):
if ev.button() == 1:
if ev.button() == Qt.MouseButton.LeftButton:
b = self.cursorForPosition(ev.pos()).block()
if b.isValid():
self.generate_sync_request(b.blockNumber())