Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

fixes some actions inheritance

  • Loading branch information...
commit 3a6028103ba6ea7aa1b1b8e5cf27f78d3f688068 1 parent 7e4cf08
Rolando Abarca authored
8 testjs/JSBindings/ScriptingCore.cpp
@@ -67,21 +67,21 @@ ScriptingCore::ScriptingCore()
67 67 S_CCRotateTo::jsCreateClass(this->cx, cocos, "RotateTo");
68 68 S_CCActionEase::jsCreateClass(this->cx, cocos, "ActionEase");
69 69 S_CCEaseRateAction::jsCreateClass(this->cx, cocos, "EaseRateAction");
  70 + S_CCEaseIn::jsCreateClass(this->cx, cocos, "EaseIn");
  71 + S_CCEaseOut::jsCreateClass(this->cx, cocos, "EaseOut");
  72 + S_CCEaseInOut::jsCreateClass(this->cx, cocos, "EaseInOut");
70 73 S_CCEaseBackInOut::jsCreateClass(this->cx, cocos, "EaseBackInOut");
71 74 S_CCEaseBackOut::jsCreateClass(this->cx, cocos, "EaseBackOut");
72 75 S_CCEaseElasticIn::jsCreateClass(this->cx, cocos, "EaseElasticIn");
73 76 S_CCEaseElastic::jsCreateClass(this->cx, cocos, "EaseElastic");
74 77 S_CCEaseElasticOut::jsCreateClass(this->cx, cocos, "EaseElasticOut");
75 78 S_CCEaseElasticInOut::jsCreateClass(this->cx, cocos, "EaseElasticInOut");
76   - S_CCEaseBounceIn::jsCreateClass(this->cx, cocos, "EaseBounceIn");
77 79 S_CCEaseBounce::jsCreateClass(this->cx, cocos, "EaseBounce");
  80 + S_CCEaseBounceIn::jsCreateClass(this->cx, cocos, "EaseBounceIn");
78 81 S_CCEaseBounceInOut::jsCreateClass(this->cx, cocos, "EaseBounceInOut");
79 82 S_CCEaseBackIn::jsCreateClass(this->cx, cocos, "EaseBackIn");
80 83 S_CCEaseBounceOut::jsCreateClass(this->cx, cocos, "EaseBounceOut");
81   - S_CCEaseIn::jsCreateClass(this->cx, cocos, "EaseIn");
82   - S_CCEaseOut::jsCreateClass(this->cx, cocos, "EaseOut");
83 84 S_CCEaseExponentialIn::jsCreateClass(this->cx, cocos, "EaseExponentialIn");
84   - S_CCEaseInOut::jsCreateClass(this->cx, cocos, "EaseInOut");
85 85 S_CCEaseExponentialOut::jsCreateClass(this->cx, cocos, "EaseExponentialOut");
86 86 S_CCEaseExponentialInOut::jsCreateClass(this->cx, cocos, "EaseExponentialInOut");
87 87 S_CCEaseSineIn::jsCreateClass(this->cx, cocos, "EaseSineIn");
520 testjs/JSBindings/out.cpp
@@ -88,6 +88,7 @@ void S_CCAnimate::jsCreateClass(JSContext *cx, JSObject *globalObj, const char *
88 88 JS_FN("initWithDuration", S_CCAnimate::jsinitWithDuration, 3, JSPROP_PERMANENT | JSPROP_SHARED),
89 89 JS_FN("startWithTarget", S_CCAnimate::jsstartWithTarget, 1, JSPROP_PERMANENT | JSPROP_SHARED),
90 90 JS_FN("stop", S_CCAnimate::jsstop, 0, JSPROP_PERMANENT | JSPROP_SHARED),
  91 + JS_FN("reverse", S_CCAnimate::jsreverse, 0, JSPROP_PERMANENT | JSPROP_SHARED),
91 92 JS_FS_END
92 93 };
93 94
@@ -179,6 +180,31 @@ JSBool S_CCAnimate::jsupdate(JSContext *cx, uint32_t argc, jsval *vp) {
179 180 JS_SET_RVAL(cx, vp, JSVAL_TRUE);
180 181 return JS_TRUE;
181 182 }
  183 +JSBool S_CCAnimate::jsreverse(JSContext *cx, uint32_t argc, jsval *vp) {
  184 + JSObject* obj = (JSObject *)JS_THIS_OBJECT(cx, vp);
  185 + S_CCAnimate* self = NULL; JSGET_PTRSHELL(S_CCAnimate, self, obj);
  186 + if (self == NULL) return JS_FALSE;
  187 + if (argc == 0) {
  188 + JS_ConvertArguments(cx, 0, JS_ARGV(cx, vp), "");
  189 + CCActionInterval* ret = self->reverse();
  190 + if (ret == NULL) {
  191 + JS_SET_RVAL(cx, vp, JSVAL_NULL);
  192 + return JS_TRUE;
  193 + }
  194 + do {
  195 + JSObject *tmp = JS_NewObject(cx, S_CCActionInterval::jsClass, S_CCActionInterval::jsObject, NULL);
  196 + pointerShell_t *pt = (pointerShell_t *)JS_malloc(cx, sizeof(pointerShell_t));
  197 + pt->flags = kPointerTemporary;
  198 + pt->data = (void *)ret;
  199 + JS_SetPrivate(tmp, pt);
  200 + JS_SET_RVAL(cx, vp, OBJECT_TO_JSVAL(tmp));
  201 + } while (0);
  202 +
  203 + return JS_TRUE;
  204 + }
  205 + JS_SET_RVAL(cx, vp, JSVAL_TRUE);
  206 + return JS_TRUE;
  207 +}
182 208 JSBool S_CCAnimate::jsactionWithAnimation(JSContext *cx, uint32_t argc, jsval *vp) {
183 209 if (argc == 1) {
184 210 JSObject *arg0;
@@ -826,6 +852,7 @@ void S_CCEaseBackOut::jsCreateClass(JSContext *cx, JSObject *globalObj, const ch
826 852 };
827 853
828 854 static JSFunctionSpec funcs[] = {
  855 + JS_FN("reverse", S_CCEaseBackOut::jsreverse, 0, JSPROP_PERMANENT | JSPROP_SHARED),
829 856 JS_FS_END
830 857 };
831 858
@@ -852,6 +879,31 @@ JSBool S_CCEaseBackOut::jsupdate(JSContext *cx, uint32_t argc, jsval *vp) {
852 879 JS_SET_RVAL(cx, vp, JSVAL_TRUE);
853 880 return JS_TRUE;
854 881 }
  882 +JSBool S_CCEaseBackOut::jsreverse(JSContext *cx, uint32_t argc, jsval *vp) {
  883 + JSObject* obj = (JSObject *)JS_THIS_OBJECT(cx, vp);
  884 + S_CCEaseBackOut* self = NULL; JSGET_PTRSHELL(S_CCEaseBackOut, self, obj);
  885 + if (self == NULL) return JS_FALSE;
  886 + if (argc == 0) {
  887 + JS_ConvertArguments(cx, 0, JS_ARGV(cx, vp), "");
  888 + CCActionInterval* ret = self->reverse();
  889 + if (ret == NULL) {
  890 + JS_SET_RVAL(cx, vp, JSVAL_NULL);
  891 + return JS_TRUE;
  892 + }
  893 + do {
  894 + JSObject *tmp = JS_NewObject(cx, S_CCActionInterval::jsClass, S_CCActionInterval::jsObject, NULL);
  895 + pointerShell_t *pt = (pointerShell_t *)JS_malloc(cx, sizeof(pointerShell_t));
  896 + pt->flags = kPointerTemporary;
  897 + pt->data = (void *)ret;
  898 + JS_SetPrivate(tmp, pt);
  899 + JS_SET_RVAL(cx, vp, OBJECT_TO_JSVAL(tmp));
  900 + } while (0);
  901 +
  902 + return JS_TRUE;
  903 + }
  904 + JS_SET_RVAL(cx, vp, JSVAL_TRUE);
  905 + return JS_TRUE;
  906 +}
855 907 JSBool S_CCEaseBackOut::jsactionWithAction(JSContext *cx, uint32_t argc, jsval *vp) {
856 908 if (argc == 1) {
857 909 JSObject *arg0;
@@ -1663,6 +1715,7 @@ void S_CCSequence::jsCreateClass(JSContext *cx, JSObject *globalObj, const char
1663 1715 JS_FN("initOneTwo", S_CCSequence::jsinitOneTwo, 2, JSPROP_PERMANENT | JSPROP_SHARED),
1664 1716 JS_FN("startWithTarget", S_CCSequence::jsstartWithTarget, 1, JSPROP_PERMANENT | JSPROP_SHARED),
1665 1717 JS_FN("stop", S_CCSequence::jsstop, 0, JSPROP_PERMANENT | JSPROP_SHARED),
  1718 + JS_FN("reverse", S_CCSequence::jsreverse, 0, JSPROP_PERMANENT | JSPROP_SHARED),
1666 1719 JS_FS_END
1667 1720 };
1668 1721
@@ -1739,6 +1792,31 @@ JSBool S_CCSequence::jsupdate(JSContext *cx, uint32_t argc, jsval *vp) {
1739 1792 JS_SET_RVAL(cx, vp, JSVAL_TRUE);
1740 1793 return JS_TRUE;
1741 1794 }
  1795 +JSBool S_CCSequence::jsreverse(JSContext *cx, uint32_t argc, jsval *vp) {
  1796 + JSObject* obj = (JSObject *)JS_THIS_OBJECT(cx, vp);
  1797 + S_CCSequence* self = NULL; JSGET_PTRSHELL(S_CCSequence, self, obj);
  1798 + if (self == NULL) return JS_FALSE;
  1799 + if (argc == 0) {
  1800 + JS_ConvertArguments(cx, 0, JS_ARGV(cx, vp), "");
  1801 + CCActionInterval* ret = self->reverse();
  1802 + if (ret == NULL) {
  1803 + JS_SET_RVAL(cx, vp, JSVAL_NULL);
  1804 + return JS_TRUE;
  1805 + }
  1806 + do {
  1807 + JSObject *tmp = JS_NewObject(cx, S_CCActionInterval::jsClass, S_CCActionInterval::jsObject, NULL);
  1808 + pointerShell_t *pt = (pointerShell_t *)JS_malloc(cx, sizeof(pointerShell_t));
  1809 + pt->flags = kPointerTemporary;
  1810 + pt->data = (void *)ret;
  1811 + JS_SetPrivate(tmp, pt);
  1812 + JS_SET_RVAL(cx, vp, OBJECT_TO_JSVAL(tmp));
  1813 + } while (0);
  1814 +
  1815 + return JS_TRUE;
  1816 + }
  1817 + JS_SET_RVAL(cx, vp, JSVAL_TRUE);
  1818 + return JS_TRUE;
  1819 +}
1742 1820 JSBool S_CCSequence::jsactions(JSContext *cx, uint32_t argc, jsval *vp) {
1743 1821 // just like CCSequence::actions
1744 1822 if (argc > 0) {
@@ -3014,6 +3092,7 @@ void S_CCEaseElasticIn::jsCreateClass(JSContext *cx, JSObject *globalObj, const
3014 3092 };
3015 3093
3016 3094 static JSFunctionSpec funcs[] = {
  3095 + JS_FN("reverse", S_CCEaseElasticIn::jsreverse, 0, JSPROP_PERMANENT | JSPROP_SHARED),
3017 3096 JS_FS_END
3018 3097 };
3019 3098
@@ -3040,6 +3119,31 @@ JSBool S_CCEaseElasticIn::jsupdate(JSContext *cx, uint32_t argc, jsval *vp) {
3040 3119 JS_SET_RVAL(cx, vp, JSVAL_TRUE);
3041 3120 return JS_TRUE;
3042 3121 }
  3122 +JSBool S_CCEaseElasticIn::jsreverse(JSContext *cx, uint32_t argc, jsval *vp) {
  3123 + JSObject* obj = (JSObject *)JS_THIS_OBJECT(cx, vp);
  3124 + S_CCEaseElasticIn* self = NULL; JSGET_PTRSHELL(S_CCEaseElasticIn, self, obj);
  3125 + if (self == NULL) return JS_FALSE;
  3126 + if (argc == 0) {
  3127 + JS_ConvertArguments(cx, 0, JS_ARGV(cx, vp), "");
  3128 + CCActionInterval* ret = self->reverse();
  3129 + if (ret == NULL) {
  3130 + JS_SET_RVAL(cx, vp, JSVAL_NULL);
  3131 + return JS_TRUE;
  3132 + }
  3133 + do {
  3134 + JSObject *tmp = JS_NewObject(cx, S_CCActionInterval::jsClass, S_CCActionInterval::jsObject, NULL);
  3135 + pointerShell_t *pt = (pointerShell_t *)JS_malloc(cx, sizeof(pointerShell_t));
  3136 + pt->flags = kPointerTemporary;
  3137 + pt->data = (void *)ret;
  3138 + JS_SetPrivate(tmp, pt);
  3139 + JS_SET_RVAL(cx, vp, OBJECT_TO_JSVAL(tmp));
  3140 + } while (0);
  3141 +
  3142 + return JS_TRUE;
  3143 + }
  3144 + JS_SET_RVAL(cx, vp, JSVAL_TRUE);
  3145 + return JS_TRUE;
  3146 +}
3043 3147 JSBool S_CCEaseElasticIn::jsactionWithAction(JSContext *cx, uint32_t argc, jsval *vp) {
3044 3148 if (argc == 1) {
3045 3149 JSObject *arg0;
@@ -3134,6 +3238,7 @@ void S_CCRotateBy::jsCreateClass(JSContext *cx, JSObject *globalObj, const char
3134 3238 static JSFunctionSpec funcs[] = {
3135 3239 JS_FN("initWithDuration", S_CCRotateBy::jsinitWithDuration, 2, JSPROP_PERMANENT | JSPROP_SHARED),
3136 3240 JS_FN("startWithTarget", S_CCRotateBy::jsstartWithTarget, 1, JSPROP_PERMANENT | JSPROP_SHARED),
  3241 + JS_FN("reverse", S_CCRotateBy::jsreverse, 0, JSPROP_PERMANENT | JSPROP_SHARED),
3137 3242 JS_FS_END
3138 3243 };
3139 3244
@@ -3192,6 +3297,31 @@ JSBool S_CCRotateBy::jsupdate(JSContext *cx, uint32_t argc, jsval *vp) {
3192 3297 JS_SET_RVAL(cx, vp, JSVAL_TRUE);
3193 3298 return JS_TRUE;
3194 3299 }
  3300 +JSBool S_CCRotateBy::jsreverse(JSContext *cx, uint32_t argc, jsval *vp) {
  3301 + JSObject* obj = (JSObject *)JS_THIS_OBJECT(cx, vp);
  3302 + S_CCRotateBy* self = NULL; JSGET_PTRSHELL(S_CCRotateBy, self, obj);
  3303 + if (self == NULL) return JS_FALSE;
  3304 + if (argc == 0) {
  3305 + JS_ConvertArguments(cx, 0, JS_ARGV(cx, vp), "");
  3306 + CCActionInterval* ret = self->reverse();
  3307 + if (ret == NULL) {
  3308 + JS_SET_RVAL(cx, vp, JSVAL_NULL);
  3309 + return JS_TRUE;
  3310 + }
  3311 + do {
  3312 + JSObject *tmp = JS_NewObject(cx, S_CCActionInterval::jsClass, S_CCActionInterval::jsObject, NULL);
  3313 + pointerShell_t *pt = (pointerShell_t *)JS_malloc(cx, sizeof(pointerShell_t));
  3314 + pt->flags = kPointerTemporary;
  3315 + pt->data = (void *)ret;
  3316 + JS_SetPrivate(tmp, pt);
  3317 + JS_SET_RVAL(cx, vp, OBJECT_TO_JSVAL(tmp));
  3318 + } while (0);
  3319 +
  3320 + return JS_TRUE;
  3321 + }
  3322 + JS_SET_RVAL(cx, vp, JSVAL_TRUE);
  3323 + return JS_TRUE;
  3324 +}
3195 3325 JSBool S_CCRotateBy::jsactionWithDuration(JSContext *cx, uint32_t argc, jsval *vp) {
3196 3326 if (argc == 2) {
3197 3327 double arg0;
@@ -3396,6 +3526,7 @@ void S_CCEaseElastic::jsCreateClass(JSContext *cx, JSObject *globalObj, const ch
3396 3526
3397 3527 static JSFunctionSpec funcs[] = {
3398 3528 JS_FN("initWithAction", S_CCEaseElastic::jsinitWithAction, 2, JSPROP_PERMANENT | JSPROP_SHARED),
  3529 + JS_FN("reverse", S_CCEaseElastic::jsreverse, 0, JSPROP_PERMANENT | JSPROP_SHARED),
3399 3530 JS_FS_END
3400 3531 };
3401 3532
@@ -3424,6 +3555,31 @@ JSBool S_CCEaseElastic::jsinitWithAction(JSContext *cx, uint32_t argc, jsval *vp
3424 3555 JS_SET_RVAL(cx, vp, JSVAL_TRUE);
3425 3556 return JS_TRUE;
3426 3557 }
  3558 +JSBool S_CCEaseElastic::jsreverse(JSContext *cx, uint32_t argc, jsval *vp) {
  3559 + JSObject* obj = (JSObject *)JS_THIS_OBJECT(cx, vp);
  3560 + S_CCEaseElastic* self = NULL; JSGET_PTRSHELL(S_CCEaseElastic, self, obj);
  3561 + if (self == NULL) return JS_FALSE;
  3562 + if (argc == 0) {
  3563 + JS_ConvertArguments(cx, 0, JS_ARGV(cx, vp), "");
  3564 + CCActionInterval* ret = self->reverse();
  3565 + if (ret == NULL) {
  3566 + JS_SET_RVAL(cx, vp, JSVAL_NULL);
  3567 + return JS_TRUE;
  3568 + }
  3569 + do {
  3570 + JSObject *tmp = JS_NewObject(cx, S_CCActionInterval::jsClass, S_CCActionInterval::jsObject, NULL);
  3571 + pointerShell_t *pt = (pointerShell_t *)JS_malloc(cx, sizeof(pointerShell_t));
  3572 + pt->flags = kPointerTemporary;
  3573 + pt->data = (void *)ret;
  3574 + JS_SetPrivate(tmp, pt);
  3575 + JS_SET_RVAL(cx, vp, OBJECT_TO_JSVAL(tmp));
  3576 + } while (0);
  3577 +
  3578 + return JS_TRUE;
  3579 + }
  3580 + JS_SET_RVAL(cx, vp, JSVAL_TRUE);
  3581 + return JS_TRUE;
  3582 +}
3427 3583 JSBool S_CCEaseElastic::jsactionWithAction(JSContext *cx, uint32_t argc, jsval *vp) {
3428 3584 if (argc == 1) {
3429 3585 JSObject *arg0;
@@ -4019,6 +4175,7 @@ void S_CCEaseElasticOut::jsCreateClass(JSContext *cx, JSObject *globalObj, const
4019 4175 };
4020 4176
4021 4177 static JSFunctionSpec funcs[] = {
  4178 + JS_FN("reverse", S_CCEaseElasticOut::jsreverse, 0, JSPROP_PERMANENT | JSPROP_SHARED),
4022 4179 JS_FS_END
4023 4180 };
4024 4181
@@ -4045,6 +4202,31 @@ JSBool S_CCEaseElasticOut::jsupdate(JSContext *cx, uint32_t argc, jsval *vp) {
4045 4202 JS_SET_RVAL(cx, vp, JSVAL_TRUE);
4046 4203 return JS_TRUE;
4047 4204 }
  4205 +JSBool S_CCEaseElasticOut::jsreverse(JSContext *cx, uint32_t argc, jsval *vp) {
  4206 + JSObject* obj = (JSObject *)JS_THIS_OBJECT(cx, vp);
  4207 + S_CCEaseElasticOut* self = NULL; JSGET_PTRSHELL(S_CCEaseElasticOut, self, obj);
  4208 + if (self == NULL) return JS_FALSE;
  4209 + if (argc == 0) {
  4210 + JS_ConvertArguments(cx, 0, JS_ARGV(cx, vp), "");
  4211 + CCActionInterval* ret = self->reverse();
  4212 + if (ret == NULL) {
  4213 + JS_SET_RVAL(cx, vp, JSVAL_NULL);
  4214 + return JS_TRUE;
  4215 + }
  4216 + do {
  4217 + JSObject *tmp = JS_NewObject(cx, S_CCActionInterval::jsClass, S_CCActionInterval::jsObject, NULL);
  4218 + pointerShell_t *pt = (pointerShell_t *)JS_malloc(cx, sizeof(pointerShell_t));
  4219 + pt->flags = kPointerTemporary;
  4220 + pt->data = (void *)ret;
  4221 + JS_SetPrivate(tmp, pt);
  4222 + JS_SET_RVAL(cx, vp, OBJECT_TO_JSVAL(tmp));
  4223 + } while (0);
  4224 +
  4225 + return JS_TRUE;
  4226 + }
  4227 + JS_SET_RVAL(cx, vp, JSVAL_TRUE);
  4228 + return JS_TRUE;
  4229 +}
4048 4230 JSBool S_CCEaseElasticOut::jsactionWithAction(JSContext *cx, uint32_t argc, jsval *vp) {
4049 4231 if (argc == 1) {
4050 4232 JSObject *arg0;
@@ -4288,6 +4470,7 @@ void S_CCEaseElasticInOut::jsCreateClass(JSContext *cx, JSObject *globalObj, con
4288 4470 };
4289 4471
4290 4472 static JSFunctionSpec funcs[] = {
  4473 + JS_FN("reverse", S_CCEaseElasticInOut::jsreverse, 0, JSPROP_PERMANENT | JSPROP_SHARED),
4291 4474 JS_FS_END
4292 4475 };
4293 4476
@@ -4314,6 +4497,31 @@ JSBool S_CCEaseElasticInOut::jsupdate(JSContext *cx, uint32_t argc, jsval *vp) {
4314 4497 JS_SET_RVAL(cx, vp, JSVAL_TRUE);
4315 4498 return JS_TRUE;
4316 4499 }
  4500 +JSBool S_CCEaseElasticInOut::jsreverse(JSContext *cx, uint32_t argc, jsval *vp) {
  4501 + JSObject* obj = (JSObject *)JS_THIS_OBJECT(cx, vp);
  4502 + S_CCEaseElasticInOut* self = NULL; JSGET_PTRSHELL(S_CCEaseElasticInOut, self, obj);
  4503 + if (self == NULL) return JS_FALSE;
  4504 + if (argc == 0) {
  4505 + JS_ConvertArguments(cx, 0, JS_ARGV(cx, vp), "");
  4506 + CCActionInterval* ret = self->reverse();
  4507 + if (ret == NULL) {
  4508 + JS_SET_RVAL(cx, vp, JSVAL_NULL);
  4509 + return JS_TRUE;
  4510 + }
  4511 + do {
  4512 + JSObject *tmp = JS_NewObject(cx, S_CCActionInterval::jsClass, S_CCActionInterval::jsObject, NULL);
  4513 + pointerShell_t *pt = (pointerShell_t *)JS_malloc(cx, sizeof(pointerShell_t));
  4514 + pt->flags = kPointerTemporary;
  4515 + pt->data = (void *)ret;
  4516 + JS_SetPrivate(tmp, pt);
  4517 + JS_SET_RVAL(cx, vp, OBJECT_TO_JSVAL(tmp));
  4518 + } while (0);
  4519 +
  4520 + return JS_TRUE;
  4521 + }
  4522 + JS_SET_RVAL(cx, vp, JSVAL_TRUE);
  4523 + return JS_TRUE;
  4524 +}
4317 4525 JSBool S_CCEaseElasticInOut::jsactionWithAction(JSContext *cx, uint32_t argc, jsval *vp) {
4318 4526 if (argc == 1) {
4319 4527 JSObject *arg0;
@@ -4404,6 +4612,7 @@ void S_CCEaseBounceIn::jsCreateClass(JSContext *cx, JSObject *globalObj, const c
4404 4612 };
4405 4613
4406 4614 static JSFunctionSpec funcs[] = {
  4615 + JS_FN("reverse", S_CCEaseBounceIn::jsreverse, 0, JSPROP_PERMANENT | JSPROP_SHARED),
4407 4616 JS_FS_END
4408 4617 };
4409 4618
@@ -4430,6 +4639,31 @@ JSBool S_CCEaseBounceIn::jsupdate(JSContext *cx, uint32_t argc, jsval *vp) {
4430 4639 JS_SET_RVAL(cx, vp, JSVAL_TRUE);
4431 4640 return JS_TRUE;
4432 4641 }
  4642 +JSBool S_CCEaseBounceIn::jsreverse(JSContext *cx, uint32_t argc, jsval *vp) {
  4643 + JSObject* obj = (JSObject *)JS_THIS_OBJECT(cx, vp);
  4644 + S_CCEaseBounceIn* self = NULL; JSGET_PTRSHELL(S_CCEaseBounceIn, self, obj);
  4645 + if (self == NULL) return JS_FALSE;
  4646 + if (argc == 0) {
  4647 + JS_ConvertArguments(cx, 0, JS_ARGV(cx, vp), "");
  4648 + CCActionInterval* ret = self->reverse();
  4649 + if (ret == NULL) {
  4650 + JS_SET_RVAL(cx, vp, JSVAL_NULL);
  4651 + return JS_TRUE;
  4652 + }
  4653 + do {
  4654 + JSObject *tmp = JS_NewObject(cx, S_CCActionInterval::jsClass, S_CCActionInterval::jsObject, NULL);
  4655 + pointerShell_t *pt = (pointerShell_t *)JS_malloc(cx, sizeof(pointerShell_t));
  4656 + pt->flags = kPointerTemporary;
  4657 + pt->data = (void *)ret;
  4658 + JS_SetPrivate(tmp, pt);
  4659 + JS_SET_RVAL(cx, vp, OBJECT_TO_JSVAL(tmp));
  4660 + } while (0);
  4661 +
  4662 + return JS_TRUE;
  4663 + }
  4664 + JS_SET_RVAL(cx, vp, JSVAL_TRUE);
  4665 + return JS_TRUE;
  4666 +}
4433 4667 JSBool S_CCEaseBounceIn::jsactionWithAction(JSContext *cx, uint32_t argc, jsval *vp) {
4434 4668 if (argc == 1) {
4435 4669 JSObject *arg0;
@@ -5020,6 +5254,7 @@ void S_CCEaseBackIn::jsCreateClass(JSContext *cx, JSObject *globalObj, const cha
5020 5254 };
5021 5255
5022 5256 static JSFunctionSpec funcs[] = {
  5257 + JS_FN("reverse", S_CCEaseBackIn::jsreverse, 0, JSPROP_PERMANENT | JSPROP_SHARED),
5023 5258 JS_FS_END
5024 5259 };
5025 5260
@@ -5046,6 +5281,31 @@ JSBool S_CCEaseBackIn::jsupdate(JSContext *cx, uint32_t argc, jsval *vp) {
5046 5281 JS_SET_RVAL(cx, vp, JSVAL_TRUE);
5047 5282 return JS_TRUE;
5048 5283 }
  5284 +JSBool S_CCEaseBackIn::jsreverse(JSContext *cx, uint32_t argc, jsval *vp) {
  5285 + JSObject* obj = (JSObject *)JS_THIS_OBJECT(cx, vp);
  5286 + S_CCEaseBackIn* self = NULL; JSGET_PTRSHELL(S_CCEaseBackIn, self, obj);
  5287 + if (self == NULL) return JS_FALSE;
  5288 + if (argc == 0) {
  5289 + JS_ConvertArguments(cx, 0, JS_ARGV(cx, vp), "");
  5290 + CCActionInterval* ret = self->reverse();
  5291 + if (ret == NULL) {
  5292 + JS_SET_RVAL(cx, vp, JSVAL_NULL);
  5293 + return JS_TRUE;
  5294 + }
  5295 + do {
  5296 + JSObject *tmp = JS_NewObject(cx, S_CCActionInterval::jsClass, S_CCActionInterval::jsObject, NULL);
  5297 + pointerShell_t *pt = (pointerShell_t *)JS_malloc(cx, sizeof(pointerShell_t));
  5298 + pt->flags = kPointerTemporary;
  5299 + pt->data = (void *)ret;
  5300 + JS_SetPrivate(tmp, pt);
  5301 + JS_SET_RVAL(cx, vp, OBJECT_TO_JSVAL(tmp));
  5302 + } while (0);
  5303 +
  5304 + return JS_TRUE;
  5305 + }
  5306 + JS_SET_RVAL(cx, vp, JSVAL_TRUE);
  5307 + return JS_TRUE;
  5308 +}
5049 5309 JSBool S_CCEaseBackIn::jsactionWithAction(JSContext *cx, uint32_t argc, jsval *vp) {
5050 5310 if (argc == 1) {
5051 5311 JSObject *arg0;
@@ -5136,6 +5396,7 @@ void S_CCEaseBounceOut::jsCreateClass(JSContext *cx, JSObject *globalObj, const
5136 5396 };
5137 5397
5138 5398 static JSFunctionSpec funcs[] = {
  5399 + JS_FN("reverse", S_CCEaseBounceOut::jsreverse, 0, JSPROP_PERMANENT | JSPROP_SHARED),
5139 5400 JS_FS_END
5140 5401 };
5141 5402
@@ -5162,6 +5423,31 @@ JSBool S_CCEaseBounceOut::jsupdate(JSContext *cx, uint32_t argc, jsval *vp) {
5162 5423 JS_SET_RVAL(cx, vp, JSVAL_TRUE);
5163 5424 return JS_TRUE;
5164 5425 }
  5426 +JSBool S_CCEaseBounceOut::jsreverse(JSContext *cx, uint32_t argc, jsval *vp) {
  5427 + JSObject* obj = (JSObject *)JS_THIS_OBJECT(cx, vp);
  5428 + S_CCEaseBounceOut* self = NULL; JSGET_PTRSHELL(S_CCEaseBounceOut, self, obj);
  5429 + if (self == NULL) return JS_FALSE;
  5430 + if (argc == 0) {
  5431 + JS_ConvertArguments(cx, 0, JS_ARGV(cx, vp), "");
  5432 + CCActionInterval* ret = self->reverse();
  5433 + if (ret == NULL) {
  5434 + JS_SET_RVAL(cx, vp, JSVAL_NULL);
  5435 + return JS_TRUE;
  5436 + }
  5437 + do {
  5438 + JSObject *tmp = JS_NewObject(cx, S_CCActionInterval::jsClass, S_CCActionInterval::jsObject, NULL);
  5439 + pointerShell_t *pt = (pointerShell_t *)JS_malloc(cx, sizeof(pointerShell_t));
  5440 + pt->flags = kPointerTemporary;
  5441 + pt->data = (void *)ret;
  5442 + JS_SetPrivate(tmp, pt);
  5443 + JS_SET_RVAL(cx, vp, OBJECT_TO_JSVAL(tmp));
  5444 + } while (0);
  5445 +
  5446 + return JS_TRUE;
  5447 + }
  5448 + JS_SET_RVAL(cx, vp, JSVAL_TRUE);
  5449 + return JS_TRUE;
  5450 +}
5165 5451 JSBool S_CCEaseBounceOut::jsactionWithAction(JSContext *cx, uint32_t argc, jsval *vp) {
5166 5452 if (argc == 1) {
5167 5453 JSObject *arg0;
@@ -6555,6 +6841,7 @@ void S_CCEaseExponentialIn::jsCreateClass(JSContext *cx, JSObject *globalObj, co
6555 6841 };
6556 6842
6557 6843 static JSFunctionSpec funcs[] = {
  6844 + JS_FN("reverse", S_CCEaseExponentialIn::jsreverse, 0, JSPROP_PERMANENT | JSPROP_SHARED),
6558 6845 JS_FS_END
6559 6846 };
6560 6847
@@ -6581,6 +6868,31 @@ JSBool S_CCEaseExponentialIn::jsupdate(JSContext *cx, uint32_t argc, jsval *vp)
6581 6868 JS_SET_RVAL(cx, vp, JSVAL_TRUE);
6582 6869 return JS_TRUE;
6583 6870 }
  6871 +JSBool S_CCEaseExponentialIn::jsreverse(JSContext *cx, uint32_t argc, jsval *vp) {
  6872 + JSObject* obj = (JSObject *)JS_THIS_OBJECT(cx, vp);
  6873 + S_CCEaseExponentialIn* self = NULL; JSGET_PTRSHELL(S_CCEaseExponentialIn, self, obj);
  6874 + if (self == NULL) return JS_FALSE;
  6875 + if (argc == 0) {
  6876 + JS_ConvertArguments(cx, 0, JS_ARGV(cx, vp), "");
  6877 + CCActionInterval* ret = self->reverse();
  6878 + if (ret == NULL) {
  6879 + JS_SET_RVAL(cx, vp, JSVAL_NULL);
  6880 + return JS_TRUE;
  6881 + }
  6882 + do {
  6883 + JSObject *tmp = JS_NewObject(cx, S_CCActionInterval::jsClass, S_CCActionInterval::jsObject, NULL);
  6884 + pointerShell_t *pt = (pointerShell_t *)JS_malloc(cx, sizeof(pointerShell_t));
  6885 + pt->flags = kPointerTemporary;
  6886 + pt->data = (void *)ret;
  6887 + JS_SetPrivate(tmp, pt);
  6888 + JS_SET_RVAL(cx, vp, OBJECT_TO_JSVAL(tmp));
  6889 + } while (0);
  6890 +
  6891 + return JS_TRUE;
  6892 + }
  6893 + JS_SET_RVAL(cx, vp, JSVAL_TRUE);
  6894 + return JS_TRUE;
  6895 +}
6584 6896 JSBool S_CCEaseExponentialIn::jsactionWithAction(JSContext *cx, uint32_t argc, jsval *vp) {
6585 6897 if (argc == 1) {
6586 6898 JSObject *arg0;
@@ -6808,6 +7120,7 @@ void S_CCEaseInOut::jsCreateClass(JSContext *cx, JSObject *globalObj, const char
6808 7120 };
6809 7121
6810 7122 static JSFunctionSpec funcs[] = {
  7123 + JS_FN("reverse", S_CCEaseInOut::jsreverse, 0, JSPROP_PERMANENT | JSPROP_SHARED),
6811 7124 JS_FS_END
6812 7125 };
6813 7126
@@ -6834,6 +7147,31 @@ JSBool S_CCEaseInOut::jsupdate(JSContext *cx, uint32_t argc, jsval *vp) {
6834 7147 JS_SET_RVAL(cx, vp, JSVAL_TRUE);
6835 7148 return JS_TRUE;
6836 7149 }
  7150 +JSBool S_CCEaseInOut::jsreverse(JSContext *cx, uint32_t argc, jsval *vp) {
  7151 + JSObject* obj = (JSObject *)JS_THIS_OBJECT(cx, vp);
  7152 + S_CCEaseInOut* self = NULL; JSGET_PTRSHELL(S_CCEaseInOut, self, obj);
  7153 + if (self == NULL) return JS_FALSE;
  7154 + if (argc == 0) {
  7155 + JS_ConvertArguments(cx, 0, JS_ARGV(cx, vp), "");
  7156 + CCActionInterval* ret = self->reverse();
  7157 + if (ret == NULL) {
  7158 + JS_SET_RVAL(cx, vp, JSVAL_NULL);
  7159 + return JS_TRUE;
  7160 + }
  7161 + do {
  7162 + JSObject *tmp = JS_NewObject(cx, S_CCActionInterval::jsClass, S_CCActionInterval::jsObject, NULL);
  7163 + pointerShell_t *pt = (pointerShell_t *)JS_malloc(cx, sizeof(pointerShell_t));
  7164 + pt->flags = kPointerTemporary;
  7165 + pt->data = (void *)ret;
  7166 + JS_SetPrivate(tmp, pt);
  7167 + JS_SET_RVAL(cx, vp, OBJECT_TO_JSVAL(tmp));
  7168 + } while (0);
  7169 +
  7170 + return JS_TRUE;
  7171 + }
  7172 + JS_SET_RVAL(cx, vp, JSVAL_TRUE);
  7173 + return JS_TRUE;
  7174 +}
6837 7175 JSBool S_CCEaseInOut::jsactionWithAction(JSContext *cx, uint32_t argc, jsval *vp) {
6838 7176 if (argc == 2) {
6839 7177 JSObject *arg0;
@@ -6925,6 +7263,7 @@ void S_CCEaseExponentialOut::jsCreateClass(JSContext *cx, JSObject *globalObj, c
6925 7263 };
6926 7264
6927 7265 static JSFunctionSpec funcs[] = {
  7266 + JS_FN("reverse", S_CCEaseExponentialOut::jsreverse, 0, JSPROP_PERMANENT | JSPROP_SHARED),
6928 7267 JS_FS_END
6929 7268 };
6930 7269
@@ -6951,6 +7290,31 @@ JSBool S_CCEaseExponentialOut::jsupdate(JSContext *cx, uint32_t argc, jsval *vp)
6951 7290 JS_SET_RVAL(cx, vp, JSVAL_TRUE);
6952 7291 return JS_TRUE;
6953 7292 }
  7293 +JSBool S_CCEaseExponentialOut::jsreverse(JSContext *cx, uint32_t argc, jsval *vp) {
  7294 + JSObject* obj = (JSObject *)JS_THIS_OBJECT(cx, vp);
  7295 + S_CCEaseExponentialOut* self = NULL; JSGET_PTRSHELL(S_CCEaseExponentialOut, self, obj);
  7296 + if (self == NULL) return JS_FALSE;
  7297 + if (argc == 0) {
  7298 + JS_ConvertArguments(cx, 0, JS_ARGV(cx, vp), "");
  7299 + CCActionInterval* ret = self->reverse();
  7300 + if (ret == NULL) {
  7301 + JS_SET_RVAL(cx, vp, JSVAL_NULL);
  7302 + return JS_TRUE;
  7303 + }
  7304 + do {
  7305 + JSObject *tmp = JS_NewObject(cx, S_CCActionInterval::jsClass, S_CCActionInterval::jsObject, NULL);
  7306 + pointerShell_t *pt = (pointerShell_t *)JS_malloc(cx, sizeof(pointerShell_t));
  7307 + pt->flags = kPointerTemporary;
  7308 + pt->data = (void *)ret;
  7309 + JS_SetPrivate(tmp, pt);
  7310 + JS_SET_RVAL(cx, vp, OBJECT_TO_JSVAL(tmp));
  7311 + } while (0);
  7312 +
  7313 + return JS_TRUE;
  7314 + }
  7315 + JS_SET_RVAL(cx, vp, JSVAL_TRUE);
  7316 + return JS_TRUE;
  7317 +}
6954 7318 JSBool S_CCEaseExponentialOut::jsactionWithAction(JSContext *cx, uint32_t argc, jsval *vp) {
6955 7319 if (argc == 1) {
6956 7320 JSObject *arg0;
@@ -8389,6 +8753,7 @@ void S_CCEaseSineIn::jsCreateClass(JSContext *cx, JSObject *globalObj, const cha
8389 8753 };
8390 8754
8391 8755 static JSFunctionSpec funcs[] = {
  8756 + JS_FN("reverse", S_CCEaseSineIn::jsreverse, 0, JSPROP_PERMANENT | JSPROP_SHARED),
8392 8757 JS_FS_END
8393 8758 };
8394 8759
@@ -8415,6 +8780,31 @@ JSBool S_CCEaseSineIn::jsupdate(JSContext *cx, uint32_t argc, jsval *vp) {
8415 8780 JS_SET_RVAL(cx, vp, JSVAL_TRUE);
8416 8781 return JS_TRUE;
8417 8782 }
  8783 +JSBool S_CCEaseSineIn::jsreverse(JSContext *cx, uint32_t argc, jsval *vp) {
  8784 + JSObject* obj = (JSObject *)JS_THIS_OBJECT(cx, vp);
  8785 + S_CCEaseSineIn* self = NULL; JSGET_PTRSHELL(S_CCEaseSineIn, self, obj);
  8786 + if (self == NULL) return JS_FALSE;
  8787 + if (argc == 0) {
  8788 + JS_ConvertArguments(cx, 0, JS_ARGV(cx, vp), "");
  8789 + CCActionInterval* ret = self->reverse();
  8790 + if (ret == NULL) {
  8791 + JS_SET_RVAL(cx, vp, JSVAL_NULL);
  8792 + return JS_TRUE;
  8793 + }
  8794 + do {
  8795 + JSObject *tmp = JS_NewObject(cx, S_CCActionInterval::jsClass, S_CCActionInterval::jsObject, NULL);
  8796 + pointerShell_t *pt = (pointerShell_t *)JS_malloc(cx, sizeof(pointerShell_t));
  8797 + pt->flags = kPointerTemporary;
  8798 + pt->data = (void *)ret;
  8799 + JS_SetPrivate(tmp, pt);
  8800 + JS_SET_RVAL(cx, vp, OBJECT_TO_JSVAL(tmp));
  8801 + } while (0);
  8802 +
  8803 + return JS_TRUE;
  8804 + }
  8805 + JS_SET_RVAL(cx, vp, JSVAL_TRUE);
  8806 + return JS_TRUE;
  8807 +}
8418 8808 JSBool S_CCEaseSineIn::jsactionWithAction(JSContext *cx, uint32_t argc, jsval *vp) {
8419 8809 if (argc == 1) {
8420 8810 JSObject *arg0;
@@ -8743,6 +9133,7 @@ void S_CCMoveBy::jsCreateClass(JSContext *cx, JSObject *globalObj, const char *n
8743 9133 static JSFunctionSpec funcs[] = {
8744 9134 JS_FN("initWithDuration", S_CCMoveBy::jsinitWithDuration, 2, JSPROP_PERMANENT | JSPROP_SHARED),
8745 9135 JS_FN("startWithTarget", S_CCMoveBy::jsstartWithTarget, 1, JSPROP_PERMANENT | JSPROP_SHARED),
  9136 + JS_FN("reverse", S_CCMoveBy::jsreverse, 0, JSPROP_PERMANENT | JSPROP_SHARED),
8746 9137 JS_FS_END
8747 9138 };
8748 9139
@@ -8787,6 +9178,31 @@ JSBool S_CCMoveBy::jsstartWithTarget(JSContext *cx, uint32_t argc, jsval *vp) {
8787 9178 JS_SET_RVAL(cx, vp, JSVAL_TRUE);
8788 9179 return JS_TRUE;
8789 9180 }
  9181 +JSBool S_CCMoveBy::jsreverse(JSContext *cx, uint32_t argc, jsval *vp) {
  9182 + JSObject* obj = (JSObject *)JS_THIS_OBJECT(cx, vp);
  9183 + S_CCMoveBy* self = NULL; JSGET_PTRSHELL(S_CCMoveBy, self, obj);
  9184 + if (self == NULL) return JS_FALSE;
  9185 + if (argc == 0) {
  9186 + JS_ConvertArguments(cx, 0, JS_ARGV(cx, vp), "");
  9187 + CCActionInterval* ret = self->reverse();
  9188 + if (ret == NULL) {
  9189 + JS_SET_RVAL(cx, vp, JSVAL_NULL);
  9190 + return JS_TRUE;
  9191 + }
  9192 + do {
  9193 + JSObject *tmp = JS_NewObject(cx, S_CCActionInterval::jsClass, S_CCActionInterval::jsObject, NULL);
  9194 + pointerShell_t *pt = (pointerShell_t *)JS_malloc(cx, sizeof(pointerShell_t));
  9195 + pt->flags = kPointerTemporary;
  9196 + pt->data = (void *)ret;
  9197 + JS_SetPrivate(tmp, pt);
  9198 + JS_SET_RVAL(cx, vp, OBJECT_TO_JSVAL(tmp));
  9199 + } while (0);
  9200 +
  9201 + return JS_TRUE;
  9202 + }
  9203 + JS_SET_RVAL(cx, vp, JSVAL_TRUE);
  9204 + return JS_TRUE;
  9205 +}
8790 9206 JSBool S_CCMoveBy::jsactionWithDuration(JSContext *cx, uint32_t argc, jsval *vp) {
8791 9207 if (argc == 2) {
8792 9208 double arg0;
@@ -8878,6 +9294,7 @@ void S_CCEaseSineOut::jsCreateClass(JSContext *cx, JSObject *globalObj, const ch
8878 9294 };
8879 9295
8880 9296 static JSFunctionSpec funcs[] = {
  9297 + JS_FN("reverse", S_CCEaseSineOut::jsreverse, 0, JSPROP_PERMANENT | JSPROP_SHARED),
8881 9298 JS_FS_END
8882 9299 };
8883 9300
@@ -8904,6 +9321,31 @@ JSBool S_CCEaseSineOut::jsupdate(JSContext *cx, uint32_t argc, jsval *vp) {
8904 9321 JS_SET_RVAL(cx, vp, JSVAL_TRUE);
8905 9322 return JS_TRUE;
8906 9323 }
  9324 +JSBool S_CCEaseSineOut::jsreverse(JSContext *cx, uint32_t argc, jsval *vp) {
  9325 + JSObject* obj = (JSObject *)JS_THIS_OBJECT(cx, vp);
  9326 + S_CCEaseSineOut* self = NULL; JSGET_PTRSHELL(S_CCEaseSineOut, self, obj);
  9327 + if (self == NULL) return JS_FALSE;
  9328 + if (argc == 0) {
  9329 + JS_ConvertArguments(cx, 0, JS_ARGV(cx, vp), "");
  9330 + CCActionInterval* ret = self->reverse();
  9331 + if (ret == NULL) {
  9332 + JS_SET_RVAL(cx, vp, JSVAL_NULL);
  9333 + return JS_TRUE;
  9334 + }
  9335 + do {
  9336 + JSObject *tmp = JS_NewObject(cx, S_CCActionInterval::jsClass, S_CCActionInterval::jsObject, NULL);
  9337 + pointerShell_t *pt = (pointerShell_t *)JS_malloc(cx, sizeof(pointerShell_t));
  9338 + pt->flags = kPointerTemporary;
  9339 + pt->data = (void *)ret;
  9340 + JS_SetPrivate(tmp, pt);
  9341 + JS_SET_RVAL(cx, vp, OBJECT_TO_JSVAL(tmp));
  9342 + } while (0);
  9343 +
  9344 + return JS_TRUE;
  9345 + }
  9346 + JS_SET_RVAL(cx, vp, JSVAL_TRUE);
  9347 + return JS_TRUE;
  9348 +}
8907 9349 JSBool S_CCEaseSineOut::jsactionWithAction(JSContext *cx, uint32_t argc, jsval *vp) {
8908 9350 if (argc == 1) {
8909 9351 JSObject *arg0;
@@ -9214,6 +9656,7 @@ void S_CCRepeatForever::jsCreateClass(JSContext *cx, JSObject *globalObj, const
9214 9656 JS_FN("startWithTarget", S_CCRepeatForever::jsstartWithTarget, 1, JSPROP_PERMANENT | JSPROP_SHARED),
9215 9657 JS_FN("step", S_CCRepeatForever::jsstep, 1, JSPROP_PERMANENT | JSPROP_SHARED),
9216 9658 JS_FN("isDone", S_CCRepeatForever::jsisDone, 0, JSPROP_PERMANENT | JSPROP_SHARED),
  9659 + JS_FN("reverse", S_CCRepeatForever::jsreverse, 0, JSPROP_PERMANENT | JSPROP_SHARED),
9217 9660 JS_FS_END
9218 9661 };
9219 9662
@@ -9286,6 +9729,31 @@ JSBool S_CCRepeatForever::jsisDone(JSContext *cx, uint32_t argc, jsval *vp) {
9286 9729 JS_SET_RVAL(cx, vp, JSVAL_TRUE);
9287 9730 return JS_TRUE;
9288 9731 }
  9732 +JSBool S_CCRepeatForever::jsreverse(JSContext *cx, uint32_t argc, jsval *vp) {
  9733 + JSObject* obj = (JSObject *)JS_THIS_OBJECT(cx, vp);
  9734 + S_CCRepeatForever* self = NULL; JSGET_PTRSHELL(S_CCRepeatForever, self, obj);
  9735 + if (self == NULL) return JS_FALSE;
  9736 + if (argc == 0) {
  9737 + JS_ConvertArguments(cx, 0, JS_ARGV(cx, vp), "");
  9738 + CCActionInterval* ret = self->reverse();
  9739 + if (ret == NULL) {
  9740 + JS_SET_RVAL(cx, vp, JSVAL_NULL);
  9741 + return JS_TRUE;
  9742 + }
  9743 + do {
  9744 + JSObject *tmp = JS_NewObject(cx, S_CCActionInterval::jsClass, S_CCActionInterval::jsObject, NULL);
  9745 + pointerShell_t *pt = (pointerShell_t *)JS_malloc(cx, sizeof(pointerShell_t));
  9746 + pt->flags = kPointerTemporary;
  9747 + pt->data = (void *)ret;
  9748 + JS_SetPrivate(tmp, pt);
  9749 + JS_SET_RVAL(cx, vp, OBJECT_TO_JSVAL(tmp));
  9750 + } while (0);
  9751 +
  9752 + return JS_TRUE;
  9753 + }
  9754 + JS_SET_RVAL(cx, vp, JSVAL_TRUE);
  9755 + return JS_TRUE;
  9756 +}
9289 9757 JSBool S_CCRepeatForever::jsactionWithAction(JSContext *cx, uint32_t argc, jsval *vp) {
9290 9758 if (argc == 1) {
9291 9759 JSObject *arg0;
@@ -9747,6 +10215,7 @@ void S_CCActionEase::jsCreateClass(JSContext *cx, JSObject *globalObj, const cha
9747 10215 JS_FN("initWithAction", S_CCActionEase::jsinitWithAction, 1, JSPROP_PERMANENT | JSPROP_SHARED),
9748 10216 JS_FN("startWithTarget", S_CCActionEase::jsstartWithTarget, 1, JSPROP_PERMANENT | JSPROP_SHARED),
9749 10217 JS_FN("stop", S_CCActionEase::jsstop, 0, JSPROP_PERMANENT | JSPROP_SHARED),
  10218 + JS_FN("reverse", S_CCActionEase::jsreverse, 0, JSPROP_PERMANENT | JSPROP_SHARED),
9750 10219 JS_FS_END
9751 10220 };
9752 10221
@@ -9819,6 +10288,31 @@ JSBool S_CCActionEase::jsupdate(JSContext *cx, uint32_t argc, jsval *vp) {
9819 10288 JS_SET_RVAL(cx, vp, JSVAL_TRUE);
9820 10289 return JS_TRUE;
9821 10290 }
  10291 +JSBool S_CCActionEase::jsreverse(JSContext *cx, uint32_t argc, jsval *vp) {
  10292 + JSObject* obj = (JSObject *)JS_THIS_OBJECT(cx, vp);
  10293 + S_CCActionEase* self = NULL; JSGET_PTRSHELL(S_CCActionEase, self, obj);
  10294 + if (self == NULL) return JS_FALSE;
  10295 + if (argc == 0) {
  10296 + JS_ConvertArguments(cx, 0, JS_ARGV(cx, vp), "");
  10297 + CCActionInterval* ret = self->reverse();
  10298 + if (ret == NULL) {
  10299 + JS_SET_RVAL(cx, vp, JSVAL_NULL);
  10300 + return JS_TRUE;
  10301 + }
  10302 + do {
  10303 + JSObject *tmp = JS_NewObject(cx, S_CCActionInterval::jsClass, S_CCActionInterval::jsObject, NULL);
  10304 + pointerShell_t *pt = (pointerShell_t *)JS_malloc(cx, sizeof(pointerShell_t));
  10305 + pt->flags = kPointerTemporary;
  10306 + pt->data = (void *)ret;
  10307 + JS_SetPrivate(tmp, pt);
  10308 + JS_SET_RVAL(cx, vp, OBJECT_TO_JSVAL(tmp));
  10309 + } while (0);
  10310 +
  10311 + return JS_TRUE;
  10312 + }
  10313 + JS_SET_RVAL(cx, vp, JSVAL_TRUE);
  10314 + return JS_TRUE;
  10315 +}
9822 10316 JSBool S_CCActionEase::jsactionWithAction(JSContext *cx, uint32_t argc, jsval *vp) {
9823 10317 if (argc == 1) {
9824 10318 JSObject *arg0;
@@ -11160,6 +11654,7 @@ void S_CCEaseRateAction::jsCreateClass(JSContext *cx, JSObject *globalObj, const
11160 11654
11161 11655 static JSFunctionSpec funcs[] = {
11162 11656 JS_FN("initWithAction", S_CCEaseRateAction::jsinitWithAction, 2, JSPROP_PERMANENT | JSPROP_SHARED),
  11657 + JS_FN("reverse", S_CCEaseRateAction::jsreverse, 0, JSPROP_PERMANENT | JSPROP_SHARED),
11163 11658 JS_FS_END
11164 11659 };
11165 11660
@@ -11188,6 +11683,31 @@ JSBool S_CCEaseRateAction::jsinitWithAction(JSContext *cx, uint32_t argc, jsval
11188 11683 JS_SET_RVAL(cx, vp, JSVAL_TRUE);
11189 11684 return JS_TRUE;
11190 11685 }
  11686 +JSBool S_CCEaseRateAction::jsreverse(JSContext *cx, uint32_t argc, jsval *vp) {
  11687 + JSObject* obj = (JSObject *)JS_THIS_OBJECT(cx, vp);
  11688 + S_CCEaseRateAction* self = NULL; JSGET_PTRSHELL(S_CCEaseRateAction, self, obj);
  11689 + if (self == NULL) return JS_FALSE;
  11690 + if (argc == 0) {
  11691 + JS_ConvertArguments(cx, 0, JS_ARGV(cx, vp), "");
  11692 + CCActionInterval* ret = self->reverse();
  11693 + if (ret == NULL) {
  11694 + JS_SET_RVAL(cx, vp, JSVAL_NULL);
  11695 + return JS_TRUE;
  11696 + }
  11697 + do {
  11698 + JSObject *tmp = JS_NewObject(cx, S_CCActionInterval::jsClass, S_CCActionInterval::jsObject, NULL);
  11699 + pointerShell_t *pt = (pointerShell_t *)JS_malloc(cx, sizeof(pointerShell_t));
  11700 + pt->flags = kPointerTemporary;
  11701 + pt->data = (void *)ret;
  11702 + JS_SetPrivate(tmp, pt);
  11703 + JS_SET_RVAL(cx, vp, OBJECT_TO_JSVAL(tmp));
  11704 + } while (0);
  11705 +
  11706 + return JS_TRUE;
  11707 + }
  11708 + JS_SET_RVAL(cx, vp, JSVAL_TRUE);
  11709 + return JS_TRUE;
  11710 +}
11191 11711 JSBool S_CCEaseRateAction::jsactionWithAction(JSContext *cx, uint32_t argc, jsval *vp) {
11192 11712 if (argc == 2) {
11193 11713 JSObject *arg0;
23 testjs/JSBindings/out.hpp
@@ -64,6 +64,7 @@ class S_CCAnimate : public CCAnimate
64 64 static JSBool jsstartWithTarget(JSContext *cx, uint32_t argc, jsval *vp);
65 65 static JSBool jsstop(JSContext *cx, uint32_t argc, jsval *vp);
66 66 static JSBool jsupdate(JSContext *cx, uint32_t argc, jsval *vp);
  67 + static JSBool jsreverse(JSContext *cx, uint32_t argc, jsval *vp);
67 68 static JSBool jsactionWithAnimation(JSContext *cx, uint32_t argc, jsval *vp);
68 69 static JSBool jsactionWithDuration(JSContext *cx, uint32_t argc, jsval *vp);
69 70
@@ -143,6 +144,7 @@ class S_CCEaseBackOut : public CCEaseBackOut
143 144 static JSBool jsPropertySet(JSContext *cx, JSObject *obj, jsid _id, JSBool strict, jsval *val);
144 145 static void jsCreateClass(JSContext *cx, JSObject *globalObj, const char *name);
145 146 static JSBool jsupdate(JSContext *cx, uint32_t argc, jsval *vp);
  147 + static JSBool jsreverse(JSContext *cx, uint32_t argc, jsval *vp);
146 148 static JSBool jsactionWithAction(JSContext *cx, uint32_t argc, jsval *vp);
147 149
148 150 };
@@ -260,6 +262,7 @@ class S_CCSequence : public CCSequence
260 262 static JSBool jsstartWithTarget(JSContext *cx, uint32_t argc, jsval *vp);
261 263 static JSBool jsstop(JSContext *cx, uint32_t argc, jsval *vp);
262 264 static JSBool jsupdate(JSContext *cx, uint32_t argc, jsval *vp);
  265 + static JSBool jsreverse(JSContext *cx, uint32_t argc, jsval *vp);
263 266 static JSBool jsactions(JSContext *cx, uint32_t argc, jsval *vp);
264 267 static JSBool jsactionsWithArray(JSContext *cx, uint32_t argc, jsval *vp);
265 268 static JSBool jsactionOneTwo(JSContext *cx, uint32_t argc, jsval *vp);
@@ -433,6 +436,7 @@ class S_CCEaseElasticIn : public CCEaseElasticIn
433 436 static JSBool jsPropertySet(JSContext *cx, JSObject *obj, jsid _id, JSBool strict, jsval *val);
434 437 static void jsCreateClass(JSContext *cx, JSObject *globalObj, const char *name);
435 438 static JSBool jsupdate(JSContext *cx, uint32_t argc, jsval *vp);
  439 + static JSBool jsreverse(JSContext *cx, uint32_t argc, jsval *vp);
436 440 static JSBool jsactionWithAction(JSContext *cx, uint32_t argc, jsval *vp);
437 441
438 442 };
@@ -458,6 +462,7 @@ class S_CCRotateBy : public CCRotateBy
458 462 static JSBool jsinitWithDuration(JSContext *cx, uint32_t argc, jsval *vp);
459 463 static JSBool jsstartWithTarget(JSContext *cx, uint32_t argc, jsval *vp);
460 464 static JSBool jsupdate(JSContext *cx, uint32_t argc, jsval *vp);
  465 + static JSBool jsreverse(JSContext *cx, uint32_t argc, jsval *vp);
461 466 static JSBool jsactionWithDuration(JSContext *cx, uint32_t argc, jsval *vp);
462 467
463 468 };
@@ -502,6 +507,7 @@ class S_CCEaseElastic : public CCEaseElastic
502 507 static JSBool jsPropertySet(JSContext *cx, JSObject *obj, jsid _id, JSBool strict, jsval *val);
503 508 static void jsCreateClass(JSContext *cx, JSObject *globalObj, const char *name);
504 509 static JSBool jsinitWithAction(JSContext *cx, uint32_t argc, jsval *vp);
  510 + static JSBool jsreverse(JSContext *cx, uint32_t argc, jsval *vp);
505 511 static JSBool jsactionWithAction(JSContext *cx, uint32_t argc, jsval *vp);
506 512
507 513 };
@@ -599,6 +605,7 @@ class S_CCEaseElasticOut : public CCEaseElasticOut
599 605 static JSBool jsPropertySet(JSContext *cx, JSObject *obj, jsid _id, JSBool strict, jsval *val);
600 606 static void jsCreateClass(JSContext *cx, JSObject *globalObj, const char *name);
601 607 static JSBool jsupdate(JSContext *cx, uint32_t argc, jsval *vp);
  608 + static JSBool jsreverse(JSContext *cx, uint32_t argc, jsval *vp);
602 609 static JSBool jsactionWithAction(JSContext *cx, uint32_t argc, jsval *vp);
603 610
604 611 };
@@ -644,6 +651,7 @@ class S_CCEaseElasticInOut : public CCEaseElasticInOut
644 651 static JSBool jsPropertySet(JSContext *cx, JSObject *obj, jsid _id, JSBool strict, jsval *val);
645 652 static void jsCreateClass(JSContext *cx, JSObject *globalObj, const char *name);
646 653 static JSBool jsupdate(JSContext *cx, uint32_t argc, jsval *vp);
  654 + static JSBool jsreverse(JSContext *cx, uint32_t argc, jsval *vp);
647 655 static JSBool jsactionWithAction(JSContext *cx, uint32_t argc, jsval *vp);
648 656
649 657 };
@@ -663,6 +671,7 @@ class S_CCEaseBounceIn : public CCEaseBounceIn
663 671 static JSBool jsPropertySet(JSContext *cx, JSObject *obj, jsid _id, JSBool strict, jsval *val);
664 672 static void jsCreateClass(JSContext *cx, JSObject *globalObj, const char *name);
665 673 static JSBool jsupdate(JSContext *cx, uint32_t argc, jsval *vp);
  674 + static JSBool jsreverse(JSContext *cx, uint32_t argc, jsval *vp);
666 675 static JSBool jsactionWithAction(JSContext *cx, uint32_t argc, jsval *vp);
667 676
668 677 };
@@ -751,6 +760,7 @@ class S_CCEaseBackIn : public CCEaseBackIn
751 760 static JSBool jsPropertySet(JSContext *cx, JSObject *obj, jsid _id, JSBool strict, jsval *val);
752 761 static void jsCreateClass(JSContext *cx, JSObject *globalObj, const char *name);
753 762 static JSBool jsupdate(JSContext *cx, uint32_t argc, jsval *vp);
  763 + static JSBool jsreverse(JSContext *cx, uint32_t argc, jsval *vp);
754 764 static JSBool jsactionWithAction(JSContext *cx, uint32_t argc, jsval *vp);
755 765
756 766 };
@@ -770,6 +780,7 @@ class S_CCEaseBounceOut : public CCEaseBounceOut
770 780 static JSBool jsPropertySet(JSContext *cx, JSObject *obj, jsid _id, JSBool strict, jsval *val);
771 781 static void jsCreateClass(JSContext *cx, JSObject *globalObj, const char *name);
772 782 static JSBool jsupdate(JSContext *cx, uint32_t argc, jsval *vp);
  783 + static JSBool jsreverse(JSContext *cx, uint32_t argc, jsval *vp);
773 784 static JSBool jsactionWithAction(JSContext *cx, uint32_t argc, jsval *vp);
774 785
775 786 };
@@ -936,6 +947,7 @@ class S_CCEaseExponentialIn : public CCEaseExponentialIn
936 947 static JSBool jsPropertySet(JSContext *cx, JSObject *obj, jsid _id, JSBool strict, jsval *val);
937 948 static void jsCreateClass(JSContext *cx, JSObject *globalObj, const char *name);
938 949 static JSBool jsupdate(JSContext *cx, uint32_t argc, jsval *vp);
  950 + static JSBool jsreverse(JSContext *cx, uint32_t argc, jsval *vp);
939 951 static JSBool jsactionWithAction(JSContext *cx, uint32_t argc, jsval *vp);
940 952
941 953 };
@@ -975,6 +987,7 @@ class S_CCEaseInOut : public CCEaseInOut
975 987 static JSBool jsPropertySet(JSContext *cx, JSObject *obj, jsid _id, JSBool strict, jsval *val);
976 988 static void jsCreateClass(JSContext *cx, JSObject *globalObj, const char *name);
977 989 static JSBool jsupdate(JSContext *cx, uint32_t argc, jsval *vp);
  990 + static JSBool jsreverse(JSContext *cx, uint32_t argc, jsval *vp);
978 991 static JSBool jsactionWithAction(JSContext *cx, uint32_t argc, jsval *vp);
979 992
980 993 };
@@ -994,6 +1007,7 @@ class S_CCEaseExponentialOut : public CCEaseExponentialOut
994 1007 static JSBool jsPropertySet(JSContext *cx, JSObject *obj, jsid _id, JSBool strict, jsval *val);
995 1008 static void jsCreateClass(JSContext *cx, JSObject *globalObj, const char *name);
996 1009 static JSBool jsupdate(JSContext *cx, uint32_t argc, jsval *vp);
  1010 + static JSBool jsreverse(JSContext *cx, uint32_t argc, jsval *vp);
997 1011 static JSBool jsactionWithAction(JSContext *cx, uint32_t argc, jsval *vp);
998 1012
999 1013 };
@@ -1210,6 +1224,7 @@ class S_CCEaseSineIn : public CCEaseSineIn
1210 1224 static JSBool jsPropertySet(JSContext *cx, JSObject *obj, jsid _id, JSBool strict, jsval *val);
1211 1225 static void jsCreateClass(JSContext *cx, JSObject *globalObj, const char *name);
1212 1226 static JSBool jsupdate(JSContext *cx, uint32_t argc, jsval *vp);
  1227 + static JSBool jsreverse(JSContext *cx, uint32_t argc, jsval *vp);
1213 1228 static JSBool jsactionWithAction(JSContext *cx, uint32_t argc, jsval *vp);
1214 1229
1215 1230 };
@@ -1244,7 +1259,8 @@ class S_CCMenuItem : public CCMenuItem
1244 1259 static JSBool jsregisterScriptHandler(JSContext *cx, uint32_t argc, jsval *vp);
1245 1260 static JSBool jsunregisterScriptHandler(JSContext *cx, uint32_t argc, jsval *vp);
1246 1261 virtual void update(ccTime delta);
1247   - void menuAction(CCObject *o);
  1262 + void menuAction(cocos2d::CCObject *o);
  1263 +
1248 1264 };
1249 1265
1250 1266 class S_CCMoveBy : public CCMoveBy
@@ -1263,6 +1279,7 @@ class S_CCMoveBy : public CCMoveBy
1263 1279 static void jsCreateClass(JSContext *cx, JSObject *globalObj, const char *name);
1264 1280 static JSBool jsinitWithDuration(JSContext *cx, uint32_t argc, jsval *vp);
1265 1281 static JSBool jsstartWithTarget(JSContext *cx, uint32_t argc, jsval *vp);
  1282 + static JSBool jsreverse(JSContext *cx, uint32_t argc, jsval *vp);
1266 1283 static JSBool jsactionWithDuration(JSContext *cx, uint32_t argc, jsval *vp);
1267 1284
1268 1285 };
@@ -1282,6 +1299,7 @@ class S_CCEaseSineOut : public CCEaseSineOut
1282 1299 static JSBool jsPropertySet(JSContext *cx, JSObject *obj, jsid _id, JSBool strict, jsval *val);
1283 1300 static void jsCreateClass(JSContext *cx, JSObject *globalObj, const char *name);
1284 1301 static JSBool jsupdate(JSContext *cx, uint32_t argc, jsval *vp);
  1302 + static JSBool jsreverse(JSContext *cx, uint32_t argc, jsval *vp);
1285 1303 static JSBool jsactionWithAction(JSContext *cx, uint32_t argc, jsval *vp);
1286 1304
1287 1305 };
@@ -1335,6 +1353,7 @@ class S_CCRepeatForever : public CCRepeatForever
1335 1353 static JSBool jsstartWithTarget(JSContext *cx, uint32_t argc, jsval *vp);
1336 1354 static JSBool jsstep(JSContext *cx, uint32_t argc, jsval *vp);
1337 1355 static JSBool jsisDone(JSContext *cx, uint32_t argc, jsval *vp);
  1356 + static JSBool jsreverse(JSContext *cx, uint32_t argc, jsval *vp);
1338 1357 static JSBool jsactionWithAction(JSContext *cx, uint32_t argc, jsval *vp);
1339 1358
1340 1359 };
@@ -1411,6 +1430,7 @@ class S_CCActionEase : public CCActionEase
1411 1430 static JSBool jsstartWithTarget(JSContext *cx, uint32_t argc, jsval *vp);
1412 1431 static JSBool jsstop(JSContext *cx, uint32_t argc, jsval *vp);
1413 1432 static JSBool jsupdate(JSContext *cx, uint32_t argc, jsval *vp);
  1433 + static JSBool jsreverse(JSContext *cx, uint32_t argc, jsval *vp);
1414 1434 static JSBool jsactionWithAction(JSContext *cx, uint32_t argc, jsval *vp);
1415 1435
1416 1436 };
@@ -1586,6 +1606,7 @@ class S_CCEaseRateAction : public CCEaseRateAction
1586 1606 static JSBool jsPropertySet(JSContext *cx, JSObject *obj, jsid _id, JSBool strict, jsval *val);
1587 1607 static void jsCreateClass(JSContext *cx, JSObject *globalObj, const char *name);
1588 1608 static JSBool jsinitWithAction(JSContext *cx, uint32_t argc, jsval *vp);
  1609 + static JSBool jsreverse(JSContext *cx, uint32_t argc, jsval *vp);
1589 1610 static JSBool jsactionWithAction(JSContext *cx, uint32_t argc, jsval *vp);
1590 1611
1591 1612 };

0 comments on commit 3a60281

Please sign in to comment.
Something went wrong with that request. Please try again.