本文整理汇总了C++中TTrigger::getName方法的典型用法代码示例。如果您正苦于以下问题:C++ TTrigger::getName方法的具体用法?C++ TTrigger::getName怎么用?C++ TTrigger::getName使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类TTrigger
的用法示例。
在下文中一共展示了TTrigger::getName方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: stopAllTriggers
void TriggerUnit::stopAllTriggers()
{
typedef list<TTrigger *>::const_iterator I;
for( I it = mTriggerRootNodeList.begin(); it != mTriggerRootNodeList.end(); it++)
{
TTrigger * pChild = *it;
QString name = pChild->getName();
pChild->disableFamily();
}
}
示例2: recurseTriggers
void dlgPackageExporter::recurseTriggers(TTrigger* trig, QTreeWidgetItem* qTrig){
list<TTrigger *> * childList = trig->getChildrenList();
if (!childList->size())
return;
list<TTrigger *>::iterator it;
for(it=childList->begin(); it!=childList->end();it++){
TTrigger * pChild = *it;
if (pChild->isTempTrigger())
continue;
QStringList sl;
sl << pChild->getName();
QTreeWidgetItem * pItem = new QTreeWidgetItem(sl);
triggerMap.insert(pItem, pChild);
pItem->setFlags(Qt::ItemIsUserCheckable|Qt::ItemIsTristate|Qt::ItemIsEnabled|Qt::ItemIsSelectable);
pItem->setCheckState(0, Qt::Unchecked);
qTrig->addChild(pItem);
recurseTriggers(pChild, pItem);
}
}
示例3: listTriggers
void dlgPackageExporter::listTriggers()
{
TriggerUnit* tu = mpHost->getTriggerUnit();
list<TTrigger *>::const_iterator it;
std::list<TTrigger *> tList = tu->getTriggerRootNodeList();
QList<QTreeWidgetItem *> items = treeWidget->findItems(QString("Triggers"), Qt::MatchExactly, 0);
QTreeWidgetItem * top = items.first();
for(it = tList.begin(); it != tList.end(); it++)
{
TTrigger * pChild = *it;
QStringList sl;
sl << pChild->getName();
QTreeWidgetItem * pItem = new QTreeWidgetItem(sl);
pItem->setFlags(Qt::ItemIsUserCheckable|Qt::ItemIsTristate|Qt::ItemIsEnabled|Qt::ItemIsSelectable);
pItem->setCheckState(0, Qt::Unchecked);
top->addChild(pItem);
triggerMap.insert(pItem, pChild);
recurseTriggers(pChild, pItem);
}
}
示例4: readTriggerGroup
//.........这里部分代码省略.........
{
if( name() == "name" )
{
pT->setName( readElementText() );
continue;
}
else if( name() == "script")
{
pT->mScript = readElementText();
continue;
}
else if( name() == "packageName")
{
pT->mPackageName = readElementText();
continue;
}
else if( name() == "triggerType" )
{
pT->mTriggerType = readElementText().toInt();
continue;
}
else if( name() == "conditonLineDelta" )
{
pT->mConditionLineDelta = readElementText().toInt();
continue;
}
else if( name() == "mStayOpen" )
{
pT->mStayOpen = readElementText().toInt();
continue;
}
else if( name() == "mCommand" )
{
pT->mCommand = readElementText();
continue;
}
else if( name() == "mFgColor")
{
pT->mFgColor.setNamedColor( readElementText() );
continue;
}
else if( name() == "mBgColor")
{
pT->mBgColor.setNamedColor( readElementText() );
continue;
}
else if( name() == "colorTriggerFgColor")
{
pT->mColorTriggerFgColor.setNamedColor( readElementText() );
continue;
}
else if( name() == "colorTriggerBgColor")
{
pT->mColorTriggerBgColor.setNamedColor( readElementText() );
continue;
}
else if( name() == "mSoundFile" )
{
pT->mSoundFile = readElementText();
continue;
}
else if( name() == "regexCodeList")
{
readStringList( pT->mRegexCodeList );
continue;
}
else if( name() == "regexCodePropertyList" )
{
readIntegerList( pT->mRegexCodePropertyList );
continue;
}
else if( name() == "TriggerGroup" )
{
readTriggerGroup( pT );
}
else if( name() == "Trigger" )
{
readTriggerGroup( pT );
}
else
{
readUnknownTriggerElement();
}
}
}
if( ! pT->setRegexCodeList( pT->mRegexCodeList, pT->mRegexCodePropertyList ) )
{
qDebug()<<"IMPORT: ERROR: cant initialize pattern list for trigger "<<pT->getName();
}
QString script = pT->mScript;
if( ! pT->setScript( script ) )
{
qDebug()<<"IMPORT: ERROR: trigger script "<< pT->getName()<<" does not compile";
}
}