With the following code, I get an error ('PySide.QtCore.Signal' object has no attribute 'emit'
) when trying to emit a signal:
#!/usr/bin/env python
from PySide import QtCore
class TestSignalClass(QtCore.QObject):
somesignal = QtCore.Signal()
def speak_me(self):
self.speak.emit()
def __init__(self):
try:
self.somesignal.emit()
except Exception as e:
print("__init__:")
print(e)
t = TestSignalClass()
What can I do to fix this?