用cocostudio做的界面,button的事件应该怎么写,我用的是cocos2dx2.2.3,
UIButton* startBtn = dynamic_cast<UIButton*>(myLayout->getChildByTag(111));
startBtn->setTouchEnabled(true);
startBtn->addTouchEventListener(this, toucheventselector(HelloWorld::queryButton));
这样写能运行,但是会挂掉,求教应该怎么写,有没有相关例子。coco升级太快,每次升级,改的东西太多,就想用2.2.3,例子太少了