2014-03-10 14:04:58 +08:00
|
|
|
|
|
|
|
--------------------------------
|
|
|
|
-- @module ControlSwitch
|
2014-03-20 10:21:28 +08:00
|
|
|
-- @extend Control
|
2014-06-25 17:36:50 +08:00
|
|
|
-- @parent_module cc
|
2014-03-18 15:55:30 +08:00
|
|
|
|
2014-03-10 14:04:58 +08:00
|
|
|
--------------------------------
|
2014-09-02 13:45:07 +08:00
|
|
|
--
|
2014-03-10 14:04:58 +08:00
|
|
|
-- @function [parent=#ControlSwitch] setEnabled
|
|
|
|
-- @param self
|
2014-09-02 13:45:07 +08:00
|
|
|
-- @param #bool enabled
|
2014-03-10 14:04:58 +08:00
|
|
|
|
|
|
|
--------------------------------
|
2014-07-17 10:28:34 +08:00
|
|
|
-- @overload self, bool
|
|
|
|
-- @overload self, bool, bool
|
2014-03-10 14:04:58 +08:00
|
|
|
-- @function [parent=#ControlSwitch] setOn
|
|
|
|
-- @param self
|
2014-09-02 13:45:07 +08:00
|
|
|
-- @param #bool isOn
|
|
|
|
-- @param #bool animated
|
2014-03-10 14:04:58 +08:00
|
|
|
|
|
|
|
--------------------------------
|
2014-09-02 13:45:07 +08:00
|
|
|
--
|
2014-03-10 14:04:58 +08:00
|
|
|
-- @function [parent=#ControlSwitch] isOn
|
|
|
|
-- @param self
|
|
|
|
-- @return bool#bool ret (return value: bool)
|
|
|
|
|
|
|
|
--------------------------------
|
2014-07-17 10:28:34 +08:00
|
|
|
-- @overload self, cc.Sprite, cc.Sprite, cc.Sprite, cc.Sprite, cc.Label, cc.Label
|
|
|
|
-- @overload self, cc.Sprite, cc.Sprite, cc.Sprite, cc.Sprite
|
2014-03-10 14:04:58 +08:00
|
|
|
-- @function [parent=#ControlSwitch] initWithMaskSprite
|
|
|
|
-- @param self
|
2014-09-02 13:45:07 +08:00
|
|
|
-- @param #cc.Sprite maskSprite
|
|
|
|
-- @param #cc.Sprite onSprite
|
|
|
|
-- @param #cc.Sprite offSprite
|
|
|
|
-- @param #cc.Sprite thumbSprite
|
|
|
|
-- @param #cc.Label onLabel
|
|
|
|
-- @param #cc.Label offLabel
|
2014-10-17 22:56:22 +08:00
|
|
|
-- @return bool#bool ret (return value: bool)
|
2014-03-10 14:04:58 +08:00
|
|
|
|
|
|
|
--------------------------------
|
2014-09-02 13:45:07 +08:00
|
|
|
--
|
2014-03-10 14:04:58 +08:00
|
|
|
-- @function [parent=#ControlSwitch] hasMoved
|
|
|
|
-- @param self
|
|
|
|
-- @return bool#bool ret (return value: bool)
|
|
|
|
|
|
|
|
--------------------------------
|
2014-09-02 13:45:07 +08:00
|
|
|
--
|
2014-03-10 14:04:58 +08:00
|
|
|
-- @function [parent=#ControlSwitch] locationFromTouch
|
|
|
|
-- @param self
|
|
|
|
-- @param #cc.Touch touch
|
2014-05-27 14:31:18 +08:00
|
|
|
-- @return vec2_table#vec2_table ret (return value: vec2_table)
|
2014-03-10 14:04:58 +08:00
|
|
|
|
|
|
|
--------------------------------
|
2014-07-17 10:28:34 +08:00
|
|
|
-- @overload self, cc.Sprite, cc.Sprite, cc.Sprite, cc.Sprite
|
|
|
|
-- @overload self, cc.Sprite, cc.Sprite, cc.Sprite, cc.Sprite, cc.Label, cc.Label
|
2014-03-10 14:04:58 +08:00
|
|
|
-- @function [parent=#ControlSwitch] create
|
|
|
|
-- @param self
|
2014-09-02 13:45:07 +08:00
|
|
|
-- @param #cc.Sprite maskSprite
|
|
|
|
-- @param #cc.Sprite onSprite
|
|
|
|
-- @param #cc.Sprite offSprite
|
|
|
|
-- @param #cc.Sprite thumbSprite
|
|
|
|
-- @param #cc.Label onLabel
|
|
|
|
-- @param #cc.Label offLabel
|
2014-10-17 22:56:22 +08:00
|
|
|
-- @return ControlSwitch#ControlSwitch ret (return value: cc.ControlSwitch)
|
2014-03-10 14:04:58 +08:00
|
|
|
|
2014-03-18 15:55:30 +08:00
|
|
|
--------------------------------
|
2014-09-02 13:45:07 +08:00
|
|
|
--
|
2014-03-18 15:55:30 +08:00
|
|
|
-- @function [parent=#ControlSwitch] onTouchMoved
|
|
|
|
-- @param self
|
2014-09-02 13:45:07 +08:00
|
|
|
-- @param #cc.Touch pTouch
|
|
|
|
-- @param #cc.Event pEvent
|
2014-03-18 15:55:30 +08:00
|
|
|
|
|
|
|
--------------------------------
|
2014-09-02 13:45:07 +08:00
|
|
|
--
|
2014-03-18 15:55:30 +08:00
|
|
|
-- @function [parent=#ControlSwitch] onTouchEnded
|
|
|
|
-- @param self
|
2014-09-02 13:45:07 +08:00
|
|
|
-- @param #cc.Touch pTouch
|
|
|
|
-- @param #cc.Event pEvent
|
2014-03-18 15:55:30 +08:00
|
|
|
|
|
|
|
--------------------------------
|
2014-09-02 13:45:07 +08:00
|
|
|
--
|
2014-03-18 15:55:30 +08:00
|
|
|
-- @function [parent=#ControlSwitch] onTouchCancelled
|
|
|
|
-- @param self
|
2014-09-02 13:45:07 +08:00
|
|
|
-- @param #cc.Touch pTouch
|
|
|
|
-- @param #cc.Event pEvent
|
2014-03-18 15:55:30 +08:00
|
|
|
|
|
|
|
--------------------------------
|
2014-09-02 13:45:07 +08:00
|
|
|
--
|
2014-03-18 15:55:30 +08:00
|
|
|
-- @function [parent=#ControlSwitch] onTouchBegan
|
|
|
|
-- @param self
|
2014-09-02 13:45:07 +08:00
|
|
|
-- @param #cc.Touch pTouch
|
|
|
|
-- @param #cc.Event pEvent
|
2014-03-18 15:55:30 +08:00
|
|
|
-- @return bool#bool ret (return value: bool)
|
|
|
|
|
2014-03-10 14:04:58 +08:00
|
|
|
--------------------------------
|
2014-09-02 13:45:07 +08:00
|
|
|
-- js ctor
|
2014-03-10 14:04:58 +08:00
|
|
|
-- @function [parent=#ControlSwitch] ControlSwitch
|
|
|
|
-- @param self
|
|
|
|
|
|
|
|
return nil
|