I have a class that implements some handlers for my glade file

The function get_handler_dict returns a dictionary of signal strings
to function handlers that are bound to the class instance self.

class SomeDialog_CohstatExport:

    def __init__(self, widgets):
        widgets.signal_autoconnect(self.get_handler_dict())        

    def get_handler_dict(self):
        m = {}
        for name in dir(self):
            if name.find('on_')==0 and callable(getattr(self, name)):
                m[name] = getattr(self, name)
        return m

    def on_button_clicked(self, event):
        #do something with self

The problem comes in if I construct this dialog twice, then when the
signal is emitted, the handlers for both the original instance and the
new instance are called.

Is there a way to disconnect the signals from the previous instance?

Thanks,
John Hunter

pygtk-1.99.14
_______________________________________________
pygtk mailing list   [EMAIL PROTECTED]
http://www.daa.com.au/mailman/listinfo/pygtk
Read the PyGTK FAQ: http://www.async.com.br/faq/pygtk/

Reply via email to