//用图片来做按钮
CCMenuItemImage* myItems = CCMenuItemImage::itemFromNormalImage( "normal.png", "down.png",
this,
menu_selector(HelloWorld::myMenuCallback));
CC_BREAK_IF(!myItems);
myItems->setPosition(ccp(size.width/2, size.height - 50));
CCMenu* myMenu = CCMenu::menuWithItems(myItems, NULL);
myMenu->setPosition(CCPointZero);
CC_BREAK_IF(!myMenu);
this->addChild(myMenu, 1);
//用文字来做按钮
CCLabelTTF* pLabel = CCLabelTTF::labelWithString("sceondMenu", "Arial",40);
CCMenuItemLabel* pItemLabel = CCMenuItemLabel::itemWithLabel(pLabel,
this, menu_selector(HelloWorld::secondMenuCallback));
CCMenu* pSecondMenu = CCMenu::menuWithItems(pItemLabel, NULL);
pItemLabel->setPosition(ccp(size.width/2, size.height-150));
pSecondMenu->setPosition(CCPointZero);
this->addChild(pSecondMenu, 2);