当前位置: 首页>>代码示例>>C++>>正文


C++ BaseQtVersion::isValid方法代码示例

本文整理汇总了C++中BaseQtVersion::isValid方法的典型用法代码示例。如果您正苦于以下问题:C++ BaseQtVersion::isValid方法的具体用法?C++ BaseQtVersion::isValid怎么用?C++ BaseQtVersion::isValid使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在BaseQtVersion的用法示例。


在下文中一共展示了BaseQtVersion::isValid方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。

示例1: createQtVersion

MerQtVersion* MerTarget::createQtVersion() const
{
    const FileName qmake = FileName::fromString(targetPath() + QLatin1Char('/') +
            QLatin1String(Constants::MER_WRAPPER_QMAKE));
    // Is there a qtversion present for this qmake?
    BaseQtVersion *qtv = QtVersionManager::qtVersionForQMakeBinary(qmake);
    if (qtv && !qtv->isValid()) {
        QtVersionManager::removeVersion(qtv);
        qtv = 0;
    }
    if (!qtv)
        qtv = new MerQtVersion(qmake, true, targetPath());

    //QtVersionFactory::createQtVersionFromQMakePath(qmake, true, targetPath());

    QTC_ASSERT(qtv && qtv->type() == QLatin1String(Constants::MER_QT), return 0);

    MerQtVersion *merqtv = static_cast<MerQtVersion *>(qtv);
    const QString vmName = m_sdk->virtualMachineName();
    merqtv->setVirtualMachineName(vmName);
    merqtv->setTargetName(m_name);
    merqtv->setUnexpandedDisplayName(
                QString::fromLatin1("Qt %1 in %2 %3").arg(qtv->qtVersionString(),
                                                          vmName, m_name));
    return merqtv;
}
开发者ID:jlehtoranta,项目名称:sailfish-qtcreator,代码行数:26,代码来源:mertarget.cpp

示例2: emitBuildDirectoryChanged

void Qt4BuildConfiguration::setShadowBuildAndDirectory(bool shadowBuild, const QString &buildDirectory)
{
    BaseQtVersion *version = QtKitInformation::qtVersion(target()->kit());
    QString directoryToSet = buildDirectory;
    bool toSet = (shadowBuild && version && version->isValid() && version->supportsShadowBuilds());
    if (m_shadowBuild == toSet && m_buildDirectory == directoryToSet)
        return;

    m_shadowBuild = toSet;
    m_buildDirectory = directoryToSet;

    emitBuildDirectoryChanged();
    emitProFileEvaluateNeeded();
}
开发者ID:kaltsi,项目名称:sailfish-qtcreator,代码行数:14,代码来源:qt4buildconfiguration.cpp

示例3: BuildConfigurationInfo

QList<BuildConfigurationInfo> Qt4BuildConfigurationFactory::availableBuildConfigurations(const Kit *k,
                                                                                         const QString &proFilePath)
{
    QList<BuildConfigurationInfo> infoList;

    BaseQtVersion *version = QtKitInformation::qtVersion(k);
    if (!version || !version->isValid())
        return infoList;
    BaseQtVersion::QmakeBuildConfigs config = version->defaultBuildConfig() | QtSupport::BaseQtVersion::DebugBuild;
    BuildConfigurationInfo info = BuildConfigurationInfo(config, QString(), QString(), false);
    info.directory = Qt4Project::shadowBuildDirectory(proFilePath, k, buildConfigurationDisplayName(info));
    infoList.append(info);

    info.buildConfig = config ^ BaseQtVersion::DebugBuild;
    info.directory = Qt4Project::shadowBuildDirectory(proFilePath, k, buildConfigurationDisplayName(info));
    infoList.append(info);
    return infoList;
}
开发者ID:kaltsi,项目名称:sailfish-qtcreator,代码行数:18,代码来源:qt4buildconfiguration.cpp


注:本文中的BaseQtVersion::isValid方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。