[PyQt] Question to the new style signals

Detlev Offenbach detlev at die-offenbachs.de
Sat Mar 19 15:10:41 GMT 2011


On Samstag, 19. März 2011, Phil Thompson wrote:
> On Sat, 19 Mar 2011 14:27:11 +0100, Detlev Offenbach
> 
> <detlev at die-offenbachs.de> wrote:
> > Hello,
> > 
> > I am using code like this to define new style signals in the classes of
> 
> my
> 
> > application.
> > 
> > class foo(QObject):
> >   signal1 = pyqtSignal(str)
> > 
> > class bar(foo):
> >   signal1 = pyqtSignal((str,), (str, str))
> > 
> > Note, that class bar is "extending" the signal. When run with a debug
> > version
> > of Qt I get a message, that class bar is redefining signal
> > signal1(QString)
> > from it's parent class. How do I correctly extend signals?
> 
> What exactly is the message?
> 
> Phil

The message is like this:

QMetaObject::indexOfSignal: signal sourceFile(QString) from ProjectBaseBrowser 
redefined in ProjectSourcesBrowser

Regards
Detlev
-- 
Detlev Offenbach
detlev at die-offenbachs.de


More information about the PyQt mailing list