cocos2d / cocos2d-html5

Cocos2d for Web Browsers. Built using JavaScript.
https://www.cocos.com
3.07k stars 902 forks source link

ccMenuItem.js, ccMenuItemToggle Example Has Bad Code #990

Closed mcscooter closed 11 years ago

mcscooter commented 11 years ago

Line 1147: * var toggler = cc.MenuItemToggle.create(this, this.callback, cc.MenuItemFont.create("On"), cc.MenuItemFont.create("Off"))

arguments are in the wrong order, should have the menuItemFont objects first:

Sorry, I didn't have time to submit a fix for this right now, maybe someone else can roll this into another change since it's just the example

mcscooter commented 11 years ago

Found time to issue an update for this https://github.com/cocos2d/cocos2d-html5/pull/991

dingpinglv commented 11 years ago

Thank you, Scott Cummings.