mirror of
https://github.com/ynput/ayon-core.git
synced 2025-12-26 22:02:15 +01:00
dont show dialog if nothing is listening to trigger_restart signal
This commit is contained in:
parent
38afc53c38
commit
1be72669a9
1 changed files with 6 additions and 0 deletions
|
|
@ -139,6 +139,12 @@ class MainWidget(QtWidgets.QWidget):
|
|||
tab_widget.reset()
|
||||
|
||||
def _on_restart_required(self):
|
||||
# Don't show dialog if there are not registered slots for
|
||||
# `trigger_restart` signal.
|
||||
# - For example when settings are runnin as standalone tool
|
||||
if self.receivers(self.trigger_restart) < 1:
|
||||
return
|
||||
|
||||
dialog = RestartDialog(self)
|
||||
result = dialog.exec_()
|
||||
if result == 1:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue