Forum > C# > CCMenuItemToggle quick click/touch bug

CCMenuItemToggle quick click/touch bug

By camelot Posted 2012-03-11 22:11 Comments 4
camelot
  • Posts: 37

1. BUG

CCMenuItemLabel itemLabelSound = createLabel("Sound");
itemLabelSound.Enabled = false;
labelOn = createLabel("On");
labelOff = createLabel("Off");
itemSound = CCMenuItemToggle.itemWithTarget(this, toggleSound, labelOn, labelOff);

CCMenuItemLabel createLabel(string value)
{
    CCLabelBMFont label = CCLabelBMFont.labelWithString(value, "fonts/verdana.fnt");
    CCMenuItemLabel itemLabel = CCMenuItemLabel.itemWithLabel(label);
    return itemLabel;
}

after compile i just quickly touch or click itemSound and its start to grow (increase in size)

2. Suggestion

Enable CodeRay in redmine for C# code hightlights (http://cocos2d-x.org/help/wiki\_syntax\_detailed.html)

s. sorry for my english

camelot
  • Posts: 37

#1 RE: 2012-03-11 22:25

you can look this bug also in cocos2d xna “tests” > “MenuTest”> “Configuragion” and start quickly clicking/touching music or sound toggle part.
as result its start growing in size

huangrh
  • Posts: 171

#2 RE: 2012-03-12 10:14

hi, Evgeniy, i have checked this, and issue http://www.cocos2d-x.org/issues/1049 has been created.

btw, are you develping games based on cocos2d-x for xna now?

camelot
  • Posts: 37

#3 RE: 2012-03-12 17:04

yes, making my first wp game.
im former flash/actionscipt game developer.

huangrh
  • Posts: 171

#4 RE: 2012-03-14 02:50

The bug has been resolved, try the latest code on the github.

Btw, do imform me when you finish your game, i am looking forward to palying it, :)

Loggin to reply

Copyright © 2010 - 2013 Cocos2d-x.orgClustrmaps