src: Project Refactoring

* Added language specific Project and ProjectSettings
* moved project specific code from Application to Project
* made Application a singleton
* added handleDialog method to Application which displays a dialog window and waits for user input
* Added ScopedFunctor that executes a function when deleted
This commit is contained in:
malte_langkabel
2016-08-11 12:17:13 +02:00
parent 6b51c7cfe4
commit c847fba568
63 changed files with 1375 additions and 874 deletions
@@ -10,7 +10,7 @@
#include "utility/solution/SolutionParserManager.h"
QtProjectWizzardContentSelect::QtProjectWizzardContentSelect(ProjectSettings* settings, QtProjectWizzardWindow* window, std::weak_ptr<SolutionParserManager> solutionParserManager)
QtProjectWizzardContentSelect::QtProjectWizzardContentSelect(std::shared_ptr<ProjectSettings> settings, QtProjectWizzardWindow* window, std::weak_ptr<SolutionParserManager> solutionParserManager)
: QtProjectWizzardContent(settings, window)
, m_solutionParserManager(solutionParserManager)
{
@@ -145,8 +145,6 @@ void QtProjectWizzardContentSelect::populateWindow(QGridLayout* layout)
void QtProjectWizzardContentSelect::save()
{
m_settings->setLanguage(m_languages->checkedButton()->text().toStdString());
ProjectType type;
switch (m_buttons->checkedId())
@@ -157,7 +155,7 @@ void QtProjectWizzardContentSelect::save()
default: type = PROJECT_MANAGED; break;
}
emit selected(type);
emit selected(stringToLanguageType(m_languages->checkedButton()->text().toStdString()), type);
}
bool QtProjectWizzardContentSelect::check()