var Handler = cc.Class({ properties: { callback: null, thisObj: null }, ctor: function(callback, thisObj) { this.callback = callback; this.thisObj = thisObj; }, execute: function(params = null) { this.callback.apply(this.thisObj, params); } });