View Single Post
Posts: 289 | Thanked: 101 times | Joined on Oct 2009
#11
Originally Posted by Diph View Post
That shouldn't be a problem.

But if you have it like this way there is a problem:

file1.h:
Code:
#include "file2.h"
file2.h
Code:
#include "file1.h"
Use forward declaration like rooster13 said.
Thats not the way I am doing it.
There is so much useless code as I am not really doing anything so I will try to explain it instead.

http://yfrog.com/j3delegatep
This is the way I want it to be. Right now there is just a listdelegate on listwindow. If I make an #include on programinfo or dayview I get the problem telling me it have already been declared.

In the listwindow.h I have #include "listdelegate.h" and in the listwindow.cpp it looks like this
Code:
lstExercises = new QListView();
    lstExercises->setModel(model);
    lstExercises->setItemDelegate(new ListDelegate(lstExercises));

Last edited by Lullen; 2010-11-15 at 21:13.