Cocos2d-x problem with ios 6.1 using CCMenuitem

Hi,

I use cocos2d-x 2.0.3 and published a ios game on appstore, but got my game rejected by Apple ONLY in ios 6.1 because the menus don’t work in this version, since I don’t have a 6.1 device I can’t test it. This bug happens in the most recent veriosn(2.1.1beta)?

In the recent ios version 6.1, has anyone see this bug?

bump I’ve got the same problem. What’s wrong with this menu setup in 2.1.1?

`void RUIMain::onEnter()
{

this->setTouchEnabled( true );

CCDirector* director = CCDirector::sharedDirector();
CCSize winSize = director->getWinSize();

CCLayerColor* background = CCLayerColor::create( ccc4( 64, 178, 150, 255 ), winSize.width, winSize.height );
this->addChild( background, Child::Z::background, Child::CCNode_background );


CCMenuItemLabel* newGame = CCMenuItemLabel::create( CCLabelTTF::create( "New Game", "adrip1.ttf", 24 ), this, menu_selector( RUIMain::callNewGame ) );

CCMenuItemLabel* loadGame = CCMenuItemLabel::create( CCLabelTTF::create( "Load Game", "adrip1.ttf", 24 ), this, menu_selector( RUIMain::callLoadGame ) );

CCMenuItemLabel* options = CCMenuItemLabel::create( CCLabelTTF::create( "Options", "adrip1.ttf", 24 ), this, menu_selector( RUIMain::callOptions ) );

CCMenuItemLabel* quit = CCMenuItemLabel::create( CCLabelTTF::create( "Quit", "adrip1.ttf", 24 ), this, menu_selector( RUIMain::callQuit ) );
quit->setColor( ccc3( 201, 176, 69 ) );
quit->setEnabled( true );

CCMenu* mainMenu = CCMenu::create( newGame, loadGame, options, quit, NULL );

this->addChild( mainMenu, Child::Z::mainMenu, Child::CCMenu_mainMenu );

mainMenu->alignItemsVerticallyWithPadding( 10 );
mainMenu->setTouchEnabled(true);
mainMenu->setEnabled(true);

}

void RUIMain::callNewGame(cocos2d::CCObject *sender)
{

}

void RUIMain::callLoadGame(cocos2d::CCObject *sender)
{

}

void RUIMain::callOptions(cocos2d::CCObject *sender)
{

}

void RUIMain::callQuit(cocos2d::CCObject *sender)
{
CCDirector::sharedDirector()->end();

#if (CC_TARGET_PLATFORM == CC_PLATFORM_IOS)
exit(0);
#endif
}`

Anyone? Is there a fix for this?

Could you describe the issue more clearly?
Do you mean that you can’t get any responses from menuitem on iOS6?

My app work perfectly in ios 5, but in iOS 6 the CCmenuitem don’t responds to touch, since my game begin with a ccmenuitem, it’s not possible to access any scene, but this is not only the problem.

My app is supposed to run only in landscape mode, in ios 5 works ok, but in ios 6 if I hold my ipod in portrait mode, the app begins in portrait mode, when I rotate the device, it assume the correct orientation and don’t go to portrait anymore, it’s a strange behavior.

Another problem that happens in my gamescreen are wrong dimensions.

I use the following code in appdelegate.cpp:

bool AppDelegate::applicationDidFinishLaunching()
{
    CCDirector *pDirector = CCDirector::sharedDirector();
    pDirector->setOpenGLView(CCEGLView::sharedOpenGLView());
    CCEGLView::sharedOpenGLView()->setDesignResolutionSize(480, 320, kResolutionExactFit);
    //pDirector->setDisplayStats(true);
    pDirector->setAnimationInterval(1.0 / 60);
    CCScene *pScene = HelloWorld::scene();
    pDirector->runWithScene(pScene);
    return true;
}

Works in ios 5 , but in ios 6 app show like if the resolution is 320x480 instead 480x320 that was set in

    CCEGLView::sharedOpenGLView()->setDesignResolutionSize(480, 320, kResolutionExactFit);

I think the problem can happen inside ‘appdelegate.mm’, but I have no idea how to modify it.

I discover I way to correct this.
I was the deploy target to ios 4.3, but If I set the deployment target to 6.1 the game works perfect in ios 6.
But if I do that, my game will not run on earlier ios 6 devices, there’s a way to maintain compatibility with older devices.