Merge remote-tracking branch 'origin/pr/3944'

This commit is contained in:
Florian Bruhin 2018-06-09 20:18:25 +02:00
commit 486a92a710
2 changed files with 12 additions and 0 deletions

View File

@ -2189,6 +2189,13 @@ fonts.web.size.minimum_logical:
maxval: maxint
desc: Minimum logical font size (in pixels) that is applied when zooming out.
## reporter
reporter.escape_quits:
type: Bool
default: True
desc: Allow escape to quit the crash reporter.
## keybindings
bindings.key_mappings:

View File

@ -158,6 +158,11 @@ class _CrashDialog(QDialog):
self._init_info_text()
self._init_buttons()
# Prevent closing :report dialogs when pressing <escape>
def keyPressEvent(self, e):
if config.val.reporter.escape_quits or e.key() != Qt.Key_Escape:
super().keyPressEvent(e)
def __repr__(self):
return utils.get_repr(self)