Sry pressed enter;) I want to split it into playerholder.h/.ccp and contactmodel.h/cpp. But it isnt wokring, i added class CONTACTMODEL; to the playerholder, inculded the contactmodel.h. The class in contactmodel.h looks like this class PLAYERHOLDER::CONTACTMODEL : public QAbstractTableModel. And it includes the playerholder.h. It gives me many error, one of them is PLAYERHOLDER: No class or namespace at the class PLAYERHOLDER:: ... line
–
diggaAug 8 '12 at 20:53

@user1585758: In my opinion you should not divide it in multiple files, both of them are part of a single component and should be managed together. If you really want to divide, the playerholder header would have just the declaration of ContactModel inside the class definition and would not include contactmodel.h, rather contactmodel.h will have to include playerholder.h to access the definition of the enclosing type and allowing the compiler to see that you are defining a nested type. Again, I would not do it, but it is feasible (and might be needed to break dependencies)
–
David Rodríguez - dribeasAug 8 '12 at 20:56