caron/PyQtForSoftimage — Issue #1: Signal and slots not disconnecting on close
Author: SimonBenAnderson
Created: 2011-11-15 06:27:04+00:00
State: open

Hey,

Have been testing the signals and slots lately and have discovered that everytime you close a dialog that has a slot connected to an event, that slot doesn't sies to exists, what happens is that slot seems to stack up with the next time you run the dialog.

So if you run the dialog 5 times in one XSI session the signal occurs five times when the event happens.

a very simple example is just add to your example plugin:
def activate( self, state = None ):
if state is not None:
if state:
self.lineedit.setText( "Welcome Back!" )
print "Welcome Back!"
and then open and close the dialog a couple times and then perform the events you will see that the welcome back message with get displayed as many times as you have opened and closed your dialog.

hope that helps :)

Si.