2014-03-10 14:04:58 +08:00
|
|
|
|
|
|
|
--------------------------------
|
|
|
|
-- @module ControlPotentiometer
|
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=#ControlPotentiometer] setPreviousLocation
|
|
|
|
-- @param self
|
2014-09-02 13:45:07 +08:00
|
|
|
-- @param #vec2_table var
|
2015-01-21 17:33:26 +08:00
|
|
|
-- @return ControlPotentiometer#ControlPotentiometer self (return value: cc.ControlPotentiometer)
|
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=#ControlPotentiometer] setValue
|
|
|
|
-- @param self
|
2014-09-02 13:45:07 +08:00
|
|
|
-- @param #float value
|
2015-01-21 17:33:26 +08:00
|
|
|
-- @return ControlPotentiometer#ControlPotentiometer self (return value: cc.ControlPotentiometer)
|
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=#ControlPotentiometer] getProgressTimer
|
|
|
|
-- @param self
|
|
|
|
-- @return ProgressTimer#ProgressTimer ret (return value: cc.ProgressTimer)
|
|
|
|
|
|
|
|
--------------------------------
|
2014-09-02 13:45:07 +08:00
|
|
|
--
|
2014-03-10 14:04:58 +08:00
|
|
|
-- @function [parent=#ControlPotentiometer] getMaximumValue
|
|
|
|
-- @param self
|
|
|
|
-- @return float#float ret (return value: float)
|
|
|
|
|
|
|
|
--------------------------------
|
2014-09-02 13:45:07 +08:00
|
|
|
-- Returns the angle in degree between line1 and line2.
|
2014-03-10 14:04:58 +08:00
|
|
|
-- @function [parent=#ControlPotentiometer] angleInDegreesBetweenLineFromPoint_toPoint_toLineFromPoint_toPoint
|
|
|
|
-- @param self
|
2014-09-02 13:45:07 +08:00
|
|
|
-- @param #vec2_table beginLineA
|
|
|
|
-- @param #vec2_table endLineA
|
|
|
|
-- @param #vec2_table beginLineB
|
|
|
|
-- @param #vec2_table endLineB
|
2014-03-10 14:04:58 +08:00
|
|
|
-- @return float#float ret (return value: float)
|
|
|
|
|
|
|
|
--------------------------------
|
2014-09-02 13:45:07 +08:00
|
|
|
-- Factorize the event dispath into these methods.
|
2014-03-10 14:04:58 +08:00
|
|
|
-- @function [parent=#ControlPotentiometer] potentiometerBegan
|
|
|
|
-- @param self
|
2014-09-02 13:45:07 +08:00
|
|
|
-- @param #vec2_table location
|
2015-01-21 17:33:26 +08:00
|
|
|
-- @return ControlPotentiometer#ControlPotentiometer self (return value: cc.ControlPotentiometer)
|
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=#ControlPotentiometer] setMaximumValue
|
|
|
|
-- @param self
|
2014-09-02 13:45:07 +08:00
|
|
|
-- @param #float maximumValue
|
2015-01-21 17:33:26 +08:00
|
|
|
-- @return ControlPotentiometer#ControlPotentiometer self (return value: cc.ControlPotentiometer)
|
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=#ControlPotentiometer] getMinimumValue
|
|
|
|
-- @param self
|
|
|
|
-- @return float#float ret (return value: float)
|
|
|
|
|
|
|
|
--------------------------------
|
2014-09-02 13:45:07 +08:00
|
|
|
--
|
2014-03-10 14:04:58 +08:00
|
|
|
-- @function [parent=#ControlPotentiometer] setThumbSprite
|
|
|
|
-- @param self
|
2014-09-02 13:45:07 +08:00
|
|
|
-- @param #cc.Sprite var
|
2015-01-21 17:33:26 +08:00
|
|
|
-- @return ControlPotentiometer#ControlPotentiometer self (return value: cc.ControlPotentiometer)
|
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=#ControlPotentiometer] getValue
|
|
|
|
-- @param self
|
|
|
|
-- @return float#float ret (return value: float)
|
|
|
|
|
|
|
|
--------------------------------
|
2014-09-02 13:45:07 +08:00
|
|
|
--
|
2014-03-10 14:04:58 +08:00
|
|
|
-- @function [parent=#ControlPotentiometer] getPreviousLocation
|
|
|
|
-- @param self
|
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-09-02 13:45:07 +08:00
|
|
|
-- Returns the distance between the point1 and point2.
|
2014-03-10 14:04:58 +08:00
|
|
|
-- @function [parent=#ControlPotentiometer] distanceBetweenPointAndPoint
|
|
|
|
-- @param self
|
2014-09-02 13:45:07 +08:00
|
|
|
-- @param #vec2_table point1
|
|
|
|
-- @param #vec2_table point2
|
2014-03-10 14:04:58 +08:00
|
|
|
-- @return float#float ret (return value: float)
|
|
|
|
|
|
|
|
--------------------------------
|
2014-09-02 13:45:07 +08:00
|
|
|
--
|
2014-03-10 14:04:58 +08:00
|
|
|
-- @function [parent=#ControlPotentiometer] potentiometerEnded
|
|
|
|
-- @param self
|
2014-09-02 13:45:07 +08:00
|
|
|
-- @param #vec2_table location
|
2015-01-21 17:33:26 +08:00
|
|
|
-- @return ControlPotentiometer#ControlPotentiometer self (return value: cc.ControlPotentiometer)
|
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=#ControlPotentiometer] setProgressTimer
|
|
|
|
-- @param self
|
2014-09-02 13:45:07 +08:00
|
|
|
-- @param #cc.ProgressTimer var
|
2015-01-21 17:33:26 +08:00
|
|
|
-- @return ControlPotentiometer#ControlPotentiometer self (return value: cc.ControlPotentiometer)
|
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=#ControlPotentiometer] setMinimumValue
|
|
|
|
-- @param self
|
2014-09-02 13:45:07 +08:00
|
|
|
-- @param #float minimumValue
|
2015-01-21 17:33:26 +08:00
|
|
|
-- @return ControlPotentiometer#ControlPotentiometer self (return value: cc.ControlPotentiometer)
|
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=#ControlPotentiometer] getThumbSprite
|
|
|
|
-- @param self
|
|
|
|
-- @return Sprite#Sprite ret (return value: cc.Sprite)
|
|
|
|
|
|
|
|
--------------------------------
|
2014-09-02 13:45:07 +08:00
|
|
|
-- Initializes a potentiometer with a track sprite and a progress bar.<br>
|
|
|
|
-- param trackSprite Sprite, that is used as a background.<br>
|
|
|
|
-- param progressTimer ProgressTimer, that is used as a progress bar.
|
2014-03-10 14:04:58 +08:00
|
|
|
-- @function [parent=#ControlPotentiometer] initWithTrackSprite_ProgressTimer_ThumbSprite
|
|
|
|
-- @param self
|
2014-09-02 13:45:07 +08:00
|
|
|
-- @param #cc.Sprite trackSprite
|
|
|
|
-- @param #cc.ProgressTimer progressTimer
|
|
|
|
-- @param #cc.Sprite thumbSprite
|
2014-03-10 14:04:58 +08:00
|
|
|
-- @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=#ControlPotentiometer] potentiometerMoved
|
|
|
|
-- @param self
|
2014-09-02 13:45:07 +08:00
|
|
|
-- @param #vec2_table location
|
2015-01-21 17:33:26 +08:00
|
|
|
-- @return ControlPotentiometer#ControlPotentiometer self (return value: cc.ControlPotentiometer)
|
2014-03-10 14:04:58 +08:00
|
|
|
|
|
|
|
--------------------------------
|
2014-09-02 13:45:07 +08:00
|
|
|
-- Creates potentiometer with a track filename and a progress filename.
|
2014-03-10 14:04:58 +08:00
|
|
|
-- @function [parent=#ControlPotentiometer] create
|
|
|
|
-- @param self
|
2014-09-02 13:45:07 +08:00
|
|
|
-- @param #char backgroundFile
|
|
|
|
-- @param #char progressFile
|
|
|
|
-- @param #char thumbFile
|
2014-03-10 14:04:58 +08:00
|
|
|
-- @return ControlPotentiometer#ControlPotentiometer ret (return value: cc.ControlPotentiometer)
|
|
|
|
|
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=#ControlPotentiometer] isTouchInside
|
|
|
|
-- @param self
|
|
|
|
-- @param #cc.Touch touch
|
|
|
|
-- @return bool#bool ret (return value: bool)
|
|
|
|
|
|
|
|
--------------------------------
|
2014-09-02 13:45:07 +08:00
|
|
|
--
|
2014-03-18 15:55:30 +08:00
|
|
|
-- @function [parent=#ControlPotentiometer] setEnabled
|
|
|
|
-- @param self
|
2014-09-02 13:45:07 +08:00
|
|
|
-- @param #bool enabled
|
2015-01-21 17:33:26 +08:00
|
|
|
-- @return ControlPotentiometer#ControlPotentiometer self (return value: cc.ControlPotentiometer)
|
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=#ControlPotentiometer] onTouchMoved
|
|
|
|
-- @param self
|
2014-09-02 13:45:07 +08:00
|
|
|
-- @param #cc.Touch pTouch
|
|
|
|
-- @param #cc.Event pEvent
|
2015-01-21 17:33:26 +08:00
|
|
|
-- @return ControlPotentiometer#ControlPotentiometer self (return value: cc.ControlPotentiometer)
|
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=#ControlPotentiometer] onTouchEnded
|
|
|
|
-- @param self
|
2014-09-02 13:45:07 +08:00
|
|
|
-- @param #cc.Touch pTouch
|
|
|
|
-- @param #cc.Event pEvent
|
2015-01-21 17:33:26 +08:00
|
|
|
-- @return ControlPotentiometer#ControlPotentiometer self (return value: cc.ControlPotentiometer)
|
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=#ControlPotentiometer] 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=#ControlPotentiometer] ControlPotentiometer
|
|
|
|
-- @param self
|
2015-01-21 17:33:26 +08:00
|
|
|
-- @return ControlPotentiometer#ControlPotentiometer self (return value: cc.ControlPotentiometer)
|
2014-03-10 14:04:58 +08:00
|
|
|
|
|
|
|
return nil
|