diff --git a/src/plugins/qmlprojectmanager/fileformat/filesystemwatcher.h b/src/plugins/qmlprojectmanager/fileformat/filesystemwatcher.h
index cc08a85b550c75e1a9e501223018ba0eb99db7be..7f9549c50ac131ef0c63e40a4ed5ff1c64ec5094 100644
--- a/src/plugins/qmlprojectmanager/fileformat/filesystemwatcher.h
+++ b/src/plugins/qmlprojectmanager/fileformat/filesystemwatcher.h
@@ -36,8 +36,10 @@
 #include <QtCore/QStringList>
 #include <QtCore/QMap>
 
+QT_BEGIN_NAMESPACE
 class QTimer;
 class QFileSystemWatcher;
+QT_END_NAMESPACE
 
 namespace QmlProjectManager {