mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
Dont try to show a dialog when calling shutdown_other with a QApplication
This commit is contained in:
parent
d8e7a58646
commit
f408f8a466
@ -437,9 +437,10 @@ def send_message(msg):
|
||||
except Exception as err:
|
||||
print(_('Failed to contact running instance of calibre'), file=sys.stderr, flush=True)
|
||||
print(err, file=sys.stderr, flush=True)
|
||||
error_dialog(None, _('Contacting calibre failed'), _(
|
||||
'Failed to contact running instance of calibre, try restarting calibre'),
|
||||
det_msg=str(err) + '\n\n' + repr(msg), show=True)
|
||||
if Application.instance():
|
||||
error_dialog(None, _('Contacting calibre failed'), _(
|
||||
'Failed to contact running instance of calibre, try restarting calibre'),
|
||||
det_msg=str(err) + '\n\n' + repr(msg), show=True)
|
||||
return False
|
||||
return True
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user