Quantcast
Channel: Cocos中文社区 - 最新帖子
Viewing all articles
Browse latest Browse all 494966

怎样监听ui节点的销毁事件

$
0
0

function bind(cb, component) {

component.on('destroy', function() {
	cb = component = undefined;
}

return function() {
    if (cb && component)
        cb.apply(component, arguments);
};

}

其中的component.on('destroy', function() {...}) 有这种事件接口吗?


Viewing all articles
Browse latest Browse all 494966

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>