A class can not be a subclass of to QObject derived classes.
My guess is that those two are visual QtQuick components, i.e. they appear visually in the QML scene. In which case they need to derive from QDeclarativeItem.
I don't know any details about their implementation but it is likely that they hold pointers to the non-UI classes, very likely indirectly through a d-pointer.
Cheers,
_
Bookmarks