Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
[dbmanager] Fix exception on older Qt builds
Fixes #19309

(cherry-picked from 9d8202b)
  • Loading branch information
nyalldawson committed Jun 30, 2018
1 parent 4a5170c commit c9f23fd
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion python/plugins/db_manager/dlg_sql_window.py
Expand Up @@ -96,7 +96,11 @@ def __init__(self, iface, db, parent=None):
self.btnCancel.setText(self.tr("Cancel (ESC)"))
self.btnCancel.setEnabled(False)
self.btnCancel.clicked.connect(self.executeSqlCanceled)
self.btnCancel.setShortcut(QKeySequence.Cancel)
try:
self.btnCancel.setShortcut(QKeySequence.Cancel)
except AttributeError:
# QKeySequence.Cancel only available in Qt >= 5.6
pass
self.progressBar.setEnabled(False)
self.progressBar.setRange(0, 100)
self.progressBar.setValue(0)
Expand Down

0 comments on commit c9f23fd

Please sign in to comment.