the 'tag' property is very useful and needed for the tests, these two lines
are duplicates, I saw that "JS_BINDED_PROP_DEF_ACCESSOR" is new, I
commented the first method but didn't want to lose the code if it needed to
switch back. The commented line can be removed

//{"tag", 0, JSPROP_ENUMERATE | JSPROP_PERMANENT | JSPROP_SHARED,
JSOP_WRAPPER(js_cocos2dx_SocketIO_setTag),
JSOP_WRAPPER(js_cocos2dx_SocketIO_getTag)}
JS_BINDED_PROP_DEF_ACCESSOR(SIOClient, tag),


On Wed, Feb 26, 2014 at 12:54 AM, James Chen <notifications@github.com>wrote:

> In cocos/scripting/javascript/bindings/network/jsb_socketio.cpp:
>
> > +void register_jsb_socketio(JSContext *cx, JSObject *global) {
> > +
> > +	js_cocos2dx_socketio_class = (JSClass *)calloc(1, sizeof(JSClass));
> > +    js_cocos2dx_socketio_class->name = "SocketIO";
> > +    js_cocos2dx_socketio_class->addProperty = JS_PropertyStub;
> > +    js_cocos2dx_socketio_class->delProperty = JS_DeletePropertyStub;
> > +    js_cocos2dx_socketio_class->getProperty = JS_PropertyStub;
> > +    js_cocos2dx_socketio_class->setProperty = JS_StrictPropertyStub;
> > +    js_cocos2dx_socketio_class->enumerate = JS_EnumerateStub;
> > +    js_cocos2dx_socketio_class->resolve = JS_ResolveStub;
> > +    js_cocos2dx_socketio_class->convert = JS_ConvertStub;
> > +    js_cocos2dx_socketio_class->finalize = js_cocos2dx_SocketIO_finalize;
> > +    js_cocos2dx_socketio_class->flags = JSCLASS_HAS_RESERVED_SLOTS(2);
> > +
> > +	static JSPropertySpec properties[] = {
> > +		//{"tag", 0, JSPROP_ENUMERATE | JSPROP_PERMANENT | JSPROP_SHARED, JSOP_WRAPPER(js_cocos2dx_SocketIO_setTag), JSOP_WRAPPER(js_cocos2dx_SocketIO_getTag)},
>
> tag is not needed?
>
> --
> Reply to this email directly or view it on GitHub<https://github.com/cocos2d/cocos2d-x/pull/5471/files#r10069226>
> .
>