void CustomExecutableRunConfiguration::restore(const PersistentSettingsReader &reader) { m_executable = reader.restoreValue("Executable").toString(); m_cmdArguments = reader.restoreValue("Arguments").toStringList(); m_workingDirectory = reader.restoreValue("WorkingDirectory").toString(); ApplicationRunConfiguration::restore(reader); }
void Qt4RunConfiguration::restore(const PersistentSettingsReader &reader) { ApplicationRunConfiguration::restore(reader); const QDir projectDir = QFileInfo(project()->file()->fileName()).absoluteDir(); m_commandLineArguments = reader.restoreValue("CommandLineArguments").toStringList(); m_proFilePath = projectDir.filePath(reader.restoreValue("ProFile").toString()); m_userSetName = reader.restoreValue("UserSetName").toBool(); m_runMode = reader.restoreValue("UseTerminal").toBool() ? Console : Gui; m_isUsingDyldImageSuffix = reader.restoreValue("UseDyldImageSuffix").toBool(); if (!m_proFilePath.isEmpty()) { m_cachedTargetInformationValid = false; if (!m_userSetName) setName(QFileInfo(m_proFilePath).completeBaseName()); } }
bool SnippetSpec::load(const QString &fileName) { PersistentSettingsReader reader; if (!reader.load(fileName)) return false; m_contents = reader.restoreValue(QLatin1String("Contents")).toString(); m_name = reader.restoreValue(QLatin1String("Name")).toString(); m_description = reader.restoreValue(QLatin1String("Description")).toString(); m_category = reader.restoreValue(QLatin1String("Category")).toString(); m_completionShortcut = reader.restoreValue(QLatin1String("Shortcut")).toString(); QMap<QString, QVariant> temp = reader.restoreValue(QLatin1String("Arguments")).toMap(); QMap<QString, QVariant>::const_iterator it, end; end = temp.constEnd(); for (it = temp.constBegin(); it != end; ++it) { m_argumentDescription.insert( it.key().toInt(), it.value().toString()); } temp = reader.restoreValue(QLatin1String("ArgumentDefaults")).toMap(); end = temp.constEnd(); for (it = temp.constBegin(); it != end; ++it) { m_argumentDefault.insert(it.key().toInt(), it.value().toString()); } return true; }
void CustomExecutableRunConfiguration::restore(const PersistentSettingsReader &reader) { m_executable = reader.restoreValue("Executable").toString(); m_cmdArguments = reader.restoreValue("Arguments").toStringList(); m_workingDirectory = reader.restoreValue("WorkingDirectory").toString(); m_runMode = reader.restoreValue("UseTerminal").toBool() ? Console : Gui; m_userSetName = reader.restoreValue("UserSetName").toBool(); m_userName = reader.restoreValue("UserName").toString(); ApplicationRunConfiguration::restore(reader); }