Commit 4ee223d4 authored by Tobias Hunger's avatar Tobias Hunger
Browse files

Add a id() method to projects

 * This makes it easier to distinguish projects in the
   userfileaccessor
parent 51fb280b
......@@ -441,6 +441,11 @@ QString CMakeProject::displayName() const
return m_projectName;
}
QString CMakeProject::id() const
{
return QLatin1String("CMakeProjectManager.CMakeProject");
}
Core::IFile *CMakeProject::file() const
{
return m_file;
......
......@@ -75,6 +75,7 @@ public:
CMakeBuildConfiguration *activeCMakeBuildConfiguration() const;
virtual QString displayName() const;
virtual QString id() const;
virtual Core::IFile *file() const;
virtual ProjectExplorer::IBuildConfigurationFactory *buildConfigurationFactory() const;
virtual CMakeManager *projectManager() const;
......
......@@ -377,6 +377,11 @@ QString GenericProject::displayName() const
return m_projectName;
}
QString GenericProject::id() const
{
return QLatin1String("GenericProjectManager.GenericProject");
}
Core::IFile *GenericProject::file() const
{
return m_file;
......
......@@ -70,6 +70,7 @@ public:
QString configFileName() const;
virtual QString displayName() const;
virtual QString id() const;
virtual Core::IFile *file() const;
virtual ProjectExplorer::IBuildConfigurationFactory *buildConfigurationFactory() const;
virtual ProjectExplorer::IProjectManager *projectManager() const;
......
......@@ -74,6 +74,7 @@ public:
virtual ~Project();
virtual QString displayName() const = 0;
virtual QString id() const = 0;
virtual Core::IFile *file() const = 0;
virtual IProjectManager *projectManager() const = 0;
......
......@@ -226,6 +226,11 @@ QString QmlProject::displayName() const
return m_projectName;
}
QString QmlProject::id() const
{
return QLatin1String("QmlProjectManager.QmlProject");
}
Core::IFile *QmlProject::file() const
{
return m_file;
......
......@@ -159,6 +159,7 @@ public:
QString filesFileName() const;
virtual QString displayName() const;
virtual QString id() const;
virtual Core::IFile *file() const;
virtual Internal::Manager *projectManager() const;
virtual ProjectExplorer::IBuildConfigurationFactory *buildConfigurationFactory() const;
......
......@@ -727,6 +727,11 @@ QString Qt4Project::displayName() const
return QFileInfo(file()->fileName()).completeBaseName();
}
QString Qt4Project::id() const
{
return QLatin1String("Qt4ProjectManager.Qt4Project");
}
Core::IFile *Qt4Project::file() const
{
return m_fileInfo;
......
......@@ -144,6 +144,7 @@ public:
Internal::Qt4BuildConfiguration *activeQt4BuildConfiguration() const;
QString displayName() const;
QString id() const;
Core::IFile *file() const;
ProjectExplorer::IProjectManager *projectManager() const;
Qt4Manager *qt4ProjectManager() const;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment