[Qt-interest] duplicate symbol

"Alexander Carôt" alexander_carot at gmx.net
Fri Oct 1 09:00:15 CEST 2010


Hi all,

I have a class, which inherits from QThread and hence cannot inherit from QWidget at the same time. As a consequence the class publically declares another QWidget, which works fine so far. However, for this widget I need to overwrite the event loop now, which forced me to subclass QWidget in my custom myQWidget class such as:

class myWidget : public QWidget{
public:
  myWidget();
  bool event(QEvent *e);
};
myWidget::myWidget(){
}
bool myWidget::event(QEvent *e){
}

This works fine until the linker tells me this:
ld: duplicate symbol myWidget::event(QEvent*) in soundjack.o and main.o

How can I fix this ?

Any hint appreciated, thanks in advance

-- A l e x



-- 
http://www.carot.de
http://www.triologue.de
Email : Alexander at Carot.de
Tel.: +49 (0)177 5719797



GRATIS: Spider-Man 1-3 sowie 300 weitere Videos!
Jetzt freischalten! http://portal.gmx.net/de/go/maxdome



More information about the Qt-interest-old mailing list