forked from qt-creator/qt-creator
ProjectExplorer: Follow up on too-much-magic in IProjectManager
Use a ProjectManager::registerProjectType<Project>(MimeType) function, removing cryptic IProjectManager object ownership. Change-Id: I212cd25bd4ee757022a8cb0decb4b8de3a112d12 Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
This commit is contained in:
@@ -26,7 +26,6 @@
|
||||
#include "genericprojectplugin.h"
|
||||
|
||||
#include "genericbuildconfiguration.h"
|
||||
#include "genericprojectmanager.h"
|
||||
#include "genericprojectwizard.h"
|
||||
#include "genericprojectconstants.h"
|
||||
#include "genericprojectfileseditor.h"
|
||||
@@ -39,6 +38,7 @@
|
||||
#include <coreplugin/actionmanager/command.h>
|
||||
|
||||
#include <projectexplorer/projectexplorerconstants.h>
|
||||
#include <projectexplorer/projectmanager.h>
|
||||
#include <projectexplorer/projecttree.h>
|
||||
#include <projectexplorer/selectablefilesmodel.h>
|
||||
|
||||
@@ -59,7 +59,8 @@ bool GenericProjectPlugin::initialize(const QStringList &, QString *errorMessage
|
||||
{
|
||||
Q_UNUSED(errorMessage)
|
||||
|
||||
addAutoReleasedObject(new Manager);
|
||||
ProjectManager::registerProjectType<GenericProject>(Constants::GENERICMIMETYPE);
|
||||
|
||||
addAutoReleasedObject(new ProjectFilesFactory);
|
||||
addAutoReleasedObject(new GenericMakeStepFactory);
|
||||
addAutoReleasedObject(new GenericBuildConfigurationFactory);
|
||||
|
||||
Reference in New Issue
Block a user