Do I understand correctly that you have two classes that inherit just A or just B and a bunch of classes that inherit both A and B? If so then if you don't need QObject at the level of A or B then if you need QObject at the level of those subclasses then inherit QObject in your bottom-most class. Just remember QObject has to go first.
class MyClass
: public QObject,
public A,
public B
{ Q_OBJECT
//...
};
class MyClass: public QObject, public A, public B {
Q_OBJECT
//...
};
To copy to clipboard, switch view to plain text mode
Bookmarks