(self, widget)
Register gobject signals in a way that avoids multiple inheritance
Register gobject signals in a way that avoids multiple inheritance
Register gobject signals in a way that avoids multiple inheritance
def register_signals(self, widget):
        """Register gobject signals in a way that avoids multiple inheritance"""
        existing = GObject.signal_list_names(widget)
        for signal in self.signals:
            if signal['name'] in existing:
                dbg('Container:: skipping signal %s for %s, already exists' % (
                        signal['name'], widget))
            else:
                dbg('Container:: registering signal for %s on %s' % 
                        (signal['name'], widget))
                try:
                    GObject.signal_new(signal['name'],
                                       widget,
                                       signal['flags'],
                                       signal['return_type'],
                                        signal['param_types'])
                except RuntimeError:
                    err('Container:: registering signal for %s on %s failed' %
                            (signal['name'], widget))
def register_signals ( self , widget ) : existing = GObject . signal_list_names ( widget ) for signal in self . signals : if signal [ 'name' ] in existing : dbg ( 'Container:: skipping signal %s for %s, already exists' % ( signal [ 'name' ] , widget ) ) else : dbg ( 'Container:: registering signal for %s on %s' % ( signal [ 'name' ] , widget ) ) try : GObject . signal_new ( signal [ 'name' ] , widget , signal [ 'flags' ] , signal [ 'return_type' ] , signal [ 'param_types' ] ) except RuntimeError : err ( 'Container:: registering signal for %s on %s failed' % ( signal [ 'name' ] , widget ) )