本文整理汇总了C++中CImageView::setId方法的典型用法代码示例。如果您正苦于以下问题:C++ CImageView::setId方法的具体用法?C++ CImageView::setId怎么用?C++ CImageView::setId使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类CImageView
的用法示例。
在下文中一共展示了CImageView::setId方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: callBackForTotalSignEffectOneFrameLater
void CSignLayer::callBackForTotalSignEffectOneFrameLater()
{
//隐藏黄标
m_pYellowTip->setVisible(false);
//触摸屏蔽
MaskLayer* pLayer1 = MaskLayer::create("CSignLayer::callBackForTotalSignEffect1");
pLayer1->setOpacity(0);
LayerManager::instance()->push(pLayer1);
MaskLayer* lay = MaskLayer::create("CSignLayer::callBackForTotalSignEffect2");
lay->setContentSize(CCSizeMake(1138,640));
lay->setAnchorPoint(ccp(0.5f, 0.5f));
lay->setPosition(VCENTER);
lay->setOpacity(0);
LayerManager::instance()->push(lay);
//开宝箱
int iIndexTotal = checkTotalBox();
if(iIndexTotal==-1)
{
//触摸释放
LayerManager::instance()->pop();
LayerManager::instance()->pop();
return;
}
int iTag = 9065+iIndexTotal;
CCString* pStr = CCString::createWithFormat("%d", iTag);
CCSpriteFrameCache::sharedSpriteFrameCache()->addSpriteFramesWithFile(CCString::createWithFormat("skill/%s.plist", pStr->getCString())->getCString());
AnimationManager::sharedAction()->ParseAnimation(pStr->getCString());
CCAnimation *culAnim = AnimationManager::sharedAction()->getAnimation(pStr->getCString());
culAnim->setDelayPerUnit(0.15f);
CCAnimate* pAnimate = CCAnimate::create(culAnim);
CImageView *mask = (CImageView*)m_ui->findWidgetById(CCString::createWithFormat("mask%d",iIndexTotal+1)->getCString());
mask->setVisible(false);
CImageView* pSprite = UICloneMgr::cloneImageView(mask);
pSprite->setVisible(true);
pSprite->setId("mask_copy");
pSprite->runAction(CCSequence::create(
pAnimate,
CCCallFunc::create(this, callfunc_selector(CSignLayer::callBackForTotalSignEffectEnd)),
nullptr
));
mask->getParent()->addChild(pSprite);
}