diff options
author | kh1 <qt-info@nokia.com> | 2010-05-25 13:43:16 +0200 |
---|---|---|
committer | kh1 <qt-info@nokia.com> | 2010-05-25 14:55:53 +0200 |
commit | 745345e347997f89f130e21bf7931fe8c6a38835 (patch) | |
tree | c914cdbf5993b099accbcac04a9ed80411077128 /src/plugins/qt4projectmanager/qt-maemo/maemomanager.cpp | |
parent | 070f4df48529de1a1693ba979261e16121b9739c (diff) | |
download | qt-creator-745345e347997f89f130e21bf7931fe8c6a38835.tar.gz |
There is no dependency, so make the runtime manager an real singelton.
Reviewed-by: ck
Diffstat (limited to 'src/plugins/qt4projectmanager/qt-maemo/maemomanager.cpp')
-rw-r--r-- | src/plugins/qt4projectmanager/qt-maemo/maemomanager.cpp | 21 |
1 files changed, 8 insertions, 13 deletions
diff --git a/src/plugins/qt4projectmanager/qt-maemo/maemomanager.cpp b/src/plugins/qt4projectmanager/qt-maemo/maemomanager.cpp index 18438e2c06..60f6a80fb5 100644 --- a/src/plugins/qt4projectmanager/qt-maemo/maemomanager.cpp +++ b/src/plugins/qt4projectmanager/qt-maemo/maemomanager.cpp @@ -44,6 +44,9 @@ #include <QtCore/QFile> #include <QtCore/QTextStream> +using namespace ExtensionSystem; +using namespace ProjectExplorer; + namespace Qt4ProjectManager { namespace Internal { @@ -59,10 +62,10 @@ MaemoManager::MaemoManager() Q_ASSERT(!m_instance); m_instance = this; + QemuRuntimeManager::instance(this); MaemoDeviceConfigurations::instance(this); - ExtensionSystem::PluginManager *pluginManager - = ExtensionSystem::PluginManager::instance(); + PluginManager *pluginManager = PluginManager::instance(); pluginManager->addObject(m_runControlFactory); pluginManager->addObject(m_runConfigurationFactory); pluginManager->addObject(m_packageCreationFactory); @@ -71,8 +74,7 @@ MaemoManager::MaemoManager() MaemoManager::~MaemoManager() { - ExtensionSystem::PluginManager *pluginManager - = ExtensionSystem::PluginManager::instance(); + PluginManager *pluginManager = PluginManager::instance(); pluginManager->removeObject(m_runControlFactory); pluginManager->removeObject(m_runConfigurationFactory); pluginManager->removeObject(m_packageCreationFactory); @@ -87,13 +89,7 @@ MaemoManager &MaemoManager::instance() return *m_instance; } -void MaemoManager::init() -{ - m_qemuRuntimeManager = new QemuRuntimeManager(this); -} - -bool -MaemoManager::isValidMaemoQtVersion(const Qt4ProjectManager::QtVersion *version) const +bool MaemoManager::isValidMaemoQtVersion(const QtVersion *version) const { QString path = QDir::cleanPath(version->qmakeCommand()); path = path.remove(QLatin1String("/bin/qmake" EXEC_SUFFIX)); @@ -116,8 +112,7 @@ MaemoManager::isValidMaemoQtVersion(const Qt4ProjectManager::QtVersion *version) return false; } -ProjectExplorer::ToolChain* -MaemoManager::maemoToolChain(const QtVersion *version) const +ToolChain* MaemoManager::maemoToolChain(const QtVersion *version) const { QString targetRoot = QDir::cleanPath(version->qmakeCommand()); targetRoot.remove(QLatin1String("/bin/qmake" EXEC_SUFFIX)); |