• CallbacksInvoker 类型
    • 索引
      • 方法
  • Details
    • 方法
      • invoke
        • 参数列表
      • add
        • 参数列表
      • hasEventListener
        • 参数列表
      • removeAll
        • 参数列表
      • remove
        • 参数列表

    CallbacksInvoker 类型

    继承于 _CallbacksHandler

    模块: _decorator父模块: cc

    CallbacksInvoker 用来根据 Key 管理并调用回调方法。

    索引

    方法
    • invoke
    • add
    • hasEventListener Check if the specified key has any registered callback. If a callback is also specified,…
    • removeAll Removes all callbacks registered in a certain event type or all callbacks registered with a certain target
    • remove

    Details

    方法

    invoke
    metadescription
    定义于cocos2d/core/platform/callbacks-invoker.js:236
    参数列表
    • key String
    • p1 Any
    • p2 Any
    • p3 Any
    • p4 Any
    • p5 Any
    add
    metadescription
    定义于cocos2d/core/platform/callbacks-invoker.js:97
    参数列表
    • key String
    • callback Function
    • target Object can be null
    hasEventListener

    Check if the specified key has any registered callback. If a callback is also specified,it will only return true if the callback is registered.

    metadescription
    返回Boolean
    定义于cocos2d/core/platform/callbacks-invoker.js:112
    参数列表
    • key String
    • callback Function
    • target Object
    removeAll

    Removes all callbacks registered in a certain event type or all callbacks registered with a certain target

    metadescription
    定义于cocos2d/core/platform/callbacks-invoker.js:154
    参数列表
    • keyOrTarget String | Object The event key to be removed or the target to be removed
    remove
    metadescription
    定义于cocos2d/core/platform/callbacks-invoker.js:192
    参数列表
    • key String
    • callback Function
    • target Object