QKeySequence.Cancel is not in 5.5

This commit is contained in:
Damien Elmes 2016-06-28 15:52:13 +10:00
parent de6ee8819f
commit eb3208e1e7

View file

@ -91,7 +91,7 @@ class AnkiWebView(QWebEngineView):
if evt.matches(QKeySequence.Paste): if evt.matches(QKeySequence.Paste):
self.onPaste() self.onPaste()
return True return True
if evt.matches(QKeySequence.Cancel): if evt.key() == Qt.Key_Escape:
# cheap hack to work around webengine swallowing escape key that # cheap hack to work around webengine swallowing escape key that
# usually closes dialogs # usually closes dialogs
w = self.parent() w = self.parent()