Commit bccbcccc authored by dt's avatar dt
Browse files

Make Console apps check the run in terminal option

parent beadef9a
......@@ -69,9 +69,11 @@ void Qt4DesktopTarget::createApplicationProFiles()
// We use the list twice
QList<Qt4ProFileNode *> profiles = qt4Project()->applicationProFiles();
QSet<QString> paths;
foreach (Qt4ProFileNode *pro, profiles)
paths << pro->path();
QHash<QString, bool> paths;
foreach (Qt4ProFileNode *pro, profiles) {
bool isConsole = pro->variableValue(ConfigVar).contains(QLatin1String("console"));
paths.insert(pro->path(), isConsole);
foreach (ProjectExplorer::RunConfiguration *rc, runConfigurations())
if (Qt4RunConfiguration *qt4rc = qobject_cast<Qt4RunConfiguration *>(rc)) {
......@@ -79,8 +81,14 @@ void Qt4DesktopTarget::createApplicationProFiles()
// Only add new runconfigurations if there are none.
foreach (const QString &path, paths)
addRunConfiguration(new Qt4RunConfiguration(this, path));
QHash<QString, bool>::const_iterator it, end;
end = paths.constEnd();
for (it = paths.constBegin(); it != end; ++it) {
Qt4RunConfiguration *qt4rc = new Qt4RunConfiguration(this, it.key());
if (it.value())
// Oh still none? Add a custom executable runconfiguration
if (runConfigurations().isEmpty()) {
......@@ -104,6 +104,7 @@ public:
Utils::OutputFormatter *createOutputFormatter() const;
void setRunMode(RunMode runMode);
void commandLineArgumentsChanged(const QString&);
void baseWorkingDirectoryChanged(const QString&);
......@@ -125,7 +126,6 @@ protected:
void handleParseState(bool success);
void setRunMode(RunMode runMode);
void setBaseWorkingDirectory(const QString &workingDirectory);
QString baseWorkingDirectory() const;
void setCommandLineArguments(const QString &argumentsString);
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