mirror of
https://github.com/ynput/ayon-core.git
synced 2026-01-02 00:44:52 +01:00
fix receivers discovery
This commit is contained in:
parent
95f9e6f65c
commit
f1ef07c7d1
1 changed files with 4 additions and 1 deletions
|
|
@ -141,7 +141,10 @@ class MainWidget(QtWidgets.QWidget):
|
|||
# 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:
|
||||
# - PySide2 and PyQt5 compatible way how to find out
|
||||
method_index = self.metaObject().indexOfMethod("trigger_restart()")
|
||||
method = self.metaObject().method(method_index)
|
||||
if not self.isSignalConnected(method):
|
||||
return
|
||||
|
||||
dialog = RestartDialog(self)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue