Commit eca6ac02 authored by Christian Kandeler's avatar Christian Kandeler
Browse files

RemoteLinux: Don't build list of deployables without valid Qt version.

Task-number: https://projects.maemo.org/bugzilla/show_bug.cgi?id=251230

Change-Id: I19f5894b52ea11590304365adae49ed148e4bd48
Reviewed-on: http://codereview.qt.nokia.com/1374

Reviewed-by: default avatarQt Sanity Bot <qt_sanity_bot@ovi.com>
Reviewed-by: default avatarTobias Hunger <tobias.hunger@nokia.com>
parent feb072b2
......@@ -263,7 +263,7 @@ bool DeployableFilesPerProFile::addDesktopFile()
}
const QtSupport::BaseQtVersion * const version = qtVersion();
QTC_ASSERT(version, return false);
QTC_ASSERT(version && version->isValid(), return false);
QString remoteDir = QLatin1String("/usr/share/applications");
if (MaemoGlobal::osType(version->qmakeCommand()) == LinuxDeviceConfiguration::Maemo5OsType)
remoteDir += QLatin1String("/hildon");
......@@ -339,7 +339,7 @@ const QtSupport::BaseQtVersion *DeployableFilesPerProFile::qtVersion() const
QString DeployableFilesPerProFile::proFileScope() const
{
const QtSupport::BaseQtVersion *const qv = qtVersion();
QTC_ASSERT(qv, return QString());
QTC_ASSERT(qv && qv->isValid(), return QString());
const QString osType = MaemoGlobal::osType(qv->qmakeCommand());
if (osType == LinuxDeviceConfiguration::Maemo5OsType)
return QLatin1String("maemo5");
......@@ -358,7 +358,7 @@ QString DeployableFilesPerProFile::installPrefix() const
QString DeployableFilesPerProFile::remoteIconDir() const
{
const QtSupport::BaseQtVersion *const qv = qtVersion();
QTC_ASSERT(qv, return QString());
QTC_ASSERT(qv && qv->isValid(), return QString());
return QString::fromLocal8Bit("/usr/share/icons/hicolor/%1x%1/apps")
.arg(MaemoGlobal::applicationIconSize(MaemoGlobal::osType(qv->qmakeCommand())));
}
......
......@@ -71,6 +71,13 @@ void DeploymentInfo::createModels()
{
if (m_target->project()->activeTarget() != m_target)
return;
if (!m_target->activeBuildConfiguration() || !m_target->activeBuildConfiguration()->qtVersion()
|| !m_target->activeBuildConfiguration()->qtVersion()->isValid()) {
beginResetModel();
m_listModels.clear();
endResetModel();
return;
}
const Qt4ProFileNode *const rootNode
= m_target->qt4Project()->rootProjectNode();
if (!rootNode || rootNode->parseInProgress()) // Can be null right after project creation by wizard.
......
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