本文整理汇总了C++中BaseQtVersion::qtVersion方法的典型用法代码示例。如果您正苦于以下问题:C++ BaseQtVersion::qtVersion方法的具体用法?C++ BaseQtVersion::qtVersion怎么用?C++ BaseQtVersion::qtVersion使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类BaseQtVersion
的用法示例。
在下文中一共展示了BaseQtVersion::qtVersion方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: foreach
// Add changed/added items:
foreach (int a, toAdd) {
BaseQtVersion *version = QtVersionManager::version(a)->clone();
m_versions.append(version);
QTreeWidgetItem *item = new QTreeWidgetItem;
item->setText(0, version->displayName());
item->setText(1, version->qmakeCommand().toUserOutput());
item->setData(0, VersionIdRole, version->uniqueId());
item->setData(0, ToolChainIdRole, defaultToolChainId(version));
const ValidityInfo info = validInformation(version);
item->setIcon(0, info.icon);
// Insert in the right place:
QTreeWidgetItem *parent = version->isAutodetected()? m_autoItem : m_manualItem;
for (int i = 0; i < parent->childCount(); ++i) {
BaseQtVersion *currentVersion = m_versions.at(indexForTreeItem(parent->child(i)));
if (currentVersion->qtVersion() > version->qtVersion())
continue;
parent->insertChild(i, item);
parent = 0;
break;
}
if (parent)
parent->addChild(item);
}
示例2: deducedArguments
QMakeStepConfig QMakeStep::deducedArguments() const
{
ProjectExplorer::Kit *kit = target()->kit();
QMakeStepConfig config;
ProjectExplorer::ToolChain *tc
= ProjectExplorer::ToolChainKitInformation::toolChain(kit);
ProjectExplorer::Abi targetAbi;
if (tc)
targetAbi = tc->targetAbi();
BaseQtVersion *version = QtKitInformation::qtVersion(target()->kit());
config.archConfig = QMakeStepConfig::targetArchFor(targetAbi, version);
config.osType = QMakeStepConfig::osTypeFor(targetAbi, version);
if (linkQmlDebuggingLibrary() && version && version->qtVersion().majorVersion >= 5)
config.linkQmlDebuggingQQ2 = true;
if (useQtQuickCompiler() && version)
config.useQtQuickCompiler = true;
if (separateDebugInfo())
config.separateDebugInfo = true;
return config;
}