We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
在代码中 bool CCMenu::ccTouchBegan(CCTouch* touch, CCEvent* event) { CC_UNUSED_PARAM(event); if (m_eState != kCCMenuStateWaiting || ! m_bVisible || !m_bEnabled) { setTouchSwallowEnabled(false); return false; }
for (CCNode *c = this->m_pParent; c != NULL; c = c->getParent()) { if (c->isVisible() == false) { setTouchSwallowEnabled(false); return false; } } m_pSelectedItem = this->itemForTouch(touch); if (m_pSelectedItem) { m_eState = kCCMenuStateTrackingTouch; m_pSelectedItem->selected(); setTouchSwallowEnabled(true); return true; } setTouchSwallowEnabled(false); return false;
}
只要有被CCMenuItem获取过 又对CCMenu设置setTouchSwallowEnabled(true); 所以即使设置为 setTouchSwallowEnabled(false); 是不生效的
The text was updated successfully, but these errors were encountered:
@YinGuiWang 是说把CCMenu设置setTouchSwallowEnabled(true),然后再设置setTouchSwallowEnabled(false),CCMenu的表现就不一样了?
Sorry, something went wrong.
No branches or pull requests
在代码中
bool CCMenu::ccTouchBegan(CCTouch* touch, CCEvent* event)
{
CC_UNUSED_PARAM(event);
if (m_eState != kCCMenuStateWaiting || ! m_bVisible || !m_bEnabled)
{
setTouchSwallowEnabled(false);
return false;
}
}
只要有被CCMenuItem获取过 又对CCMenu设置setTouchSwallowEnabled(true); 所以即使设置为 setTouchSwallowEnabled(false); 是不生效的
The text was updated successfully, but these errors were encountered: