forked from qt-creator/qt-creator
iosrunconfiguration: use more descriptive method/variables names
removed use of shortened names Change-Id: Icce8558a909e6fdd1c4d4f12ea273745fb21f5eb Reviewed-by: Fawzi Mohamed <fawzi.mohamed@digia.com>
This commit is contained in:
@@ -87,7 +87,7 @@ RunControl *IosAnalyzeSupport::createAnalyzeRunControl(IosRunConfiguration *runC
|
||||
params.runMode = QmlProfilerRunMode;
|
||||
params.sysroot = SysRootKitInformation::sysRoot(target->kit()).toString();
|
||||
params.startMode = StartLocal;
|
||||
params.debuggee = runConfig->exePath().toUserOutput();
|
||||
params.debuggee = runConfig->localExecutable().toUserOutput();
|
||||
params.debuggeeArgs = Utils::QtcProcess::joinArgs(runConfig->commandLineArguments());
|
||||
params.analyzerHost = QLatin1String("localhost");
|
||||
if (device->type() == Core::Id(Ios::Constants::IOS_DEVICE_TYPE)) {
|
||||
@@ -95,7 +95,7 @@ RunControl *IosAnalyzeSupport::createAnalyzeRunControl(IosRunConfiguration *runC
|
||||
if (iosDevice.isNull())
|
||||
return 0;
|
||||
}
|
||||
params.displayName = runConfig->appName();
|
||||
params.displayName = runConfig->applicationName();
|
||||
|
||||
AnalyzerRunControl *analyzerRunControl = AnalyzerManager::createRunControl(params, runConfig);
|
||||
(void) new IosAnalyzeSupport(runConfig, analyzerRunControl, false, true);
|
||||
|
@@ -114,7 +114,7 @@ RunControl *IosDebugSupport::createDebugRunControl(IosRunConfiguration *runConfi
|
||||
params.startMode = AttachExternal;
|
||||
params.platform = QLatin1String("ios-simulator");
|
||||
}
|
||||
params.displayName = runConfig->appName();
|
||||
params.displayName = runConfig->applicationName();
|
||||
params.remoteSetupNeeded = true;
|
||||
if (!params.breakOnMain)
|
||||
params.continueAfterAttach = true;
|
||||
@@ -129,7 +129,7 @@ RunControl *IosDebugSupport::createDebugRunControl(IosRunConfiguration *runConfi
|
||||
params.debuggerCommand = DebuggerKitInformation::debuggerCommand(kit).toString();
|
||||
if (ToolChain *tc = ToolChainKitInformation::toolChain(kit))
|
||||
params.toolChainAbi = tc->targetAbi();
|
||||
params.executable = runConfig->exePath().toString();
|
||||
params.executable = runConfig->localExecutable().toString();
|
||||
params.remoteChannel = QLatin1String("connect://localhost:0");
|
||||
|
||||
Utils::FileName xcodeInfo = IosConfigurations::developerPath().parentDir()
|
||||
@@ -142,7 +142,7 @@ RunControl *IosDebugSupport::createDebugRunControl(IosRunConfiguration *runConfi
|
||||
if (version.value(0).toInt() == 5 && version.value(1, QString::number(1)).toInt() == 0)
|
||||
buggyLldb = true;
|
||||
}
|
||||
QString bundlePath = runConfig->bundleDir().toString();
|
||||
QString bundlePath = runConfig->bundleDirectory().toString();
|
||||
bundlePath.chop(4);
|
||||
Utils::FileName dsymPath = Utils::FileName::fromString(
|
||||
bundlePath.append(QLatin1String(".dSYM")));
|
||||
@@ -153,7 +153,7 @@ RunControl *IosDebugSupport::createDebugRunControl(IosRunConfiguration *runConfi
|
||||
"To create one, add a dsymutil deploystep."),
|
||||
ProjectExplorer::Constants::TASK_CATEGORY_DEPLOYMENT);
|
||||
} else if (dsymPath.toFileInfo().lastModified()
|
||||
< QFileInfo(runConfig->exePath().toUserOutput()).lastModified()) {
|
||||
< QFileInfo(runConfig->localExecutable().toUserOutput()).lastModified()) {
|
||||
TaskHub::addTask(Task::Warning,
|
||||
tr("The dSYM %1 seems to be outdated, it might confuse the debugger.")
|
||||
.arg(dsymPath.toUserOutput()),
|
||||
|
@@ -89,7 +89,7 @@ bool IosDeployStep::init()
|
||||
IosRunConfiguration * runConfig = qobject_cast<IosRunConfiguration *>(
|
||||
this->target()->activeRunConfiguration());
|
||||
QTC_CHECK(runConfig);
|
||||
m_bundlePath = runConfig->bundleDir().toString();
|
||||
m_bundlePath = runConfig->bundleDirectory().toString();
|
||||
if (m_device.isNull()) {
|
||||
emit addOutput(tr("Error: no device available, deploy failed."),
|
||||
BuildStep::ErrorMessageOutput);
|
||||
|
@@ -436,7 +436,7 @@ QStringList IosDsymBuildStep::defaultCleanCmdList() const
|
||||
IosRunConfiguration *runConf =
|
||||
qobject_cast<IosRunConfiguration *>(target()->activeRunConfiguration());
|
||||
QTC_ASSERT(runConf, return QStringList(QLatin1String("echo")));
|
||||
QString dsymPath = runConf->bundleDir().toUserOutput();
|
||||
QString dsymPath = runConf->bundleDirectory().toUserOutput();
|
||||
dsymPath.chop(4);
|
||||
dsymPath.append(QLatin1String(".dSYM"));
|
||||
return QStringList()
|
||||
@@ -455,14 +455,14 @@ QStringList IosDsymBuildStep::defaultCmdList() const
|
||||
IosRunConfiguration *runConf =
|
||||
qobject_cast<IosRunConfiguration *>(target()->activeRunConfiguration());
|
||||
QTC_ASSERT(runConf, return QStringList(QLatin1String("echo")));
|
||||
QString dsymPath = runConf->bundleDir().toUserOutput();
|
||||
QString dsymPath = runConf->bundleDirectory().toUserOutput();
|
||||
dsymPath.chop(4);
|
||||
dsymPath.append(QLatin1String(".dSYM"));
|
||||
return QStringList()
|
||||
<< dsymutilCmd
|
||||
<< QLatin1String("-o")
|
||||
<< dsymPath
|
||||
<< runConf->exePath().toUserOutput();
|
||||
<< runConf->localExecutable().toUserOutput();
|
||||
}
|
||||
|
||||
|
||||
|
@@ -166,7 +166,7 @@ void IosRunConfiguration::updateDisplayNames()
|
||||
ProjectExplorer::DeviceKitInformation::device(target()->kit());
|
||||
const QString devName = dev.isNull() ? IosDevice::name() : dev->displayName();
|
||||
setDefaultDisplayName(tr("Run on %1").arg(devName));
|
||||
setDisplayName(tr("Run %1 on %2").arg(appName()).arg(devName));
|
||||
setDisplayName(tr("Run %1 on %2").arg(applicationName()).arg(devName));
|
||||
}
|
||||
|
||||
IosDeployStep *IosRunConfiguration::deployStep() const
|
||||
@@ -191,7 +191,7 @@ QString IosRunConfiguration::profilePath() const
|
||||
return m_profilePath;
|
||||
}
|
||||
|
||||
QString IosRunConfiguration::appName() const
|
||||
QString IosRunConfiguration::applicationName() const
|
||||
{
|
||||
QmakeProject *pro = qobject_cast<QmakeProject *>(target()->project());
|
||||
const QmakeProFileNode *node = 0;
|
||||
@@ -207,7 +207,7 @@ QString IosRunConfiguration::appName() const
|
||||
return QString();
|
||||
}
|
||||
|
||||
Utils::FileName IosRunConfiguration::bundleDir() const
|
||||
Utils::FileName IosRunConfiguration::bundleDirectory() const
|
||||
{
|
||||
Utils::FileName res;
|
||||
Core::Id devType = ProjectExplorer::DeviceTypeKitInformation::deviceTypeId(target()->kit());
|
||||
@@ -251,13 +251,13 @@ Utils::FileName IosRunConfiguration::bundleDir() const
|
||||
<< target()->activeBuildConfiguration()->buildType();
|
||||
}
|
||||
}
|
||||
res.appendPath(appName() + QLatin1String(".app"));
|
||||
res.appendPath(applicationName() + QLatin1String(".app"));
|
||||
return res;
|
||||
}
|
||||
|
||||
Utils::FileName IosRunConfiguration::exePath() const
|
||||
Utils::FileName IosRunConfiguration::localExecutable() const
|
||||
{
|
||||
return bundleDir().appendPath(appName());
|
||||
return bundleDirectory().appendPath(applicationName());
|
||||
}
|
||||
|
||||
bool IosRunConfiguration::fromMap(const QVariantMap &map)
|
||||
@@ -455,7 +455,7 @@ void IosRunConfigurationWidget::updateValues()
|
||||
if (simulatedDevices[i] == m_runConfiguration->deviceType())
|
||||
m_ui->deviceTypeComboBox->setCurrentIndex(i);
|
||||
m_ui->argumentsLineEdit->setText(argsString);
|
||||
m_ui->executableLineEdit->setText(m_runConfiguration->exePath().toUserOutput());
|
||||
m_ui->executableLineEdit->setText(m_runConfiguration->localExecutable().toUserOutput());
|
||||
}
|
||||
|
||||
} // namespace Internal
|
||||
|
@@ -71,9 +71,9 @@ public:
|
||||
|
||||
QStringList commandLineArguments();
|
||||
QString profilePath() const;
|
||||
QString appName() const;
|
||||
Utils::FileName bundleDir() const;
|
||||
Utils::FileName exePath() const;
|
||||
QString applicationName() const;
|
||||
Utils::FileName bundleDirectory() const;
|
||||
Utils::FileName localExecutable() const;
|
||||
bool isEnabled() const;
|
||||
QString disabledReason() const;
|
||||
IosDeviceType::Enum deviceType() const;
|
||||
|
@@ -56,7 +56,7 @@ namespace Ios {
|
||||
namespace Internal {
|
||||
|
||||
IosRunner::IosRunner(QObject *parent, IosRunConfiguration *runConfig, bool cppDebug, bool qmlDebug)
|
||||
: QObject(parent), m_toolHandler(0), m_bundleDir(runConfig->bundleDir().toString()),
|
||||
: QObject(parent), m_toolHandler(0), m_bundleDir(runConfig->bundleDirectory().toString()),
|
||||
m_arguments(runConfig->commandLineArguments()),
|
||||
m_device(ProjectExplorer::DeviceKitInformation::device(runConfig->target()->kit())),
|
||||
m_cppDebug(cppDebug), m_qmlDebug(qmlDebug), m_cleanExit(false),
|
||||
|
Reference in New Issue
Block a user