Hi,

I'm fairly new to Qt.

In a larger GUI programming project, on Linux with Qt Creator 5.2. Now I need to split things up and therefor make som tests

I'm about to make a namespace test and in order for that, I create a new QApplication, compile out of the box - OK
Next I add a new C++ class that inherit from QObject.
Straight out of the box, it compiles

Now when I add the class it fails to compile straight of with two errors
Error: all: "No such file or directory"
[first] Error 1

Guess it has to do with paths missing but where??
Suggestions??

Qt Code:
  1. #include <QMainWindow>
  2.  
  3. namespace Ui { class MainWindow; }
  4.  
  5. class MainWindow : public QMainWindow
  6. {
  7. Q_OBJECT
  8.  
  9. public:
  10. explicit MainWindow(QWidget *parent = 0);
  11. ~MainWindow();
  12.  
  13. ....
  14.  
  15.  
  16. #include <QObject>
  17.  
  18. class First : public QObject
  19. {
  20. Q_OBJECT
  21. public:
  22. explicit First(QObject *parent = 0);
  23.  
  24. signals:
  25. ...
  26.  
  27. // in .cpp
  28. #include "first.h"
  29.  
  30. First::First(QObject *parent) :
  31. QObject(parent)
  32. {
  33. }
To copy to clipboard, switch view to plain text mode