Merge pull request #4347 from samuele3hu/developTableView

[ci skip]Add doxygen comments for the CocoStudio
This commit is contained in:
minggo 2013-11-20 21:55:34 -08:00
commit 4582686860
49 changed files with 456 additions and 178 deletions

View File

@ -39,6 +39,10 @@ enum FrameType
kKeyframeMax
};
/**
* @js NA
* @lua NA
*/
class ActionFrame:public cocos2d::Object
{
@ -125,6 +129,10 @@ protected:
float _fTime;
};
/**
* @js NA
* @lua NA
*/
class ActionMoveFrame:public ActionFrame
{
public:
@ -165,6 +173,10 @@ protected:
cocos2d::Point _position;
};
/**
* @js NA
* @lua NA
*/
class ActionScaleFrame:public ActionFrame
{
public:
@ -219,7 +231,10 @@ protected:
float _scaleX;
float _scaleY;
};
/**
* @js NA
* @lua NA
*/
class ActionRotationFrame:public ActionFrame
{
public:
@ -259,7 +274,10 @@ public:
protected:
float _rotation;
};
/**
* @js NA
* @lua NA
*/
class ActionFadeFrame:public ActionFrame
{
public:
@ -299,7 +317,10 @@ public:
protected:
float _opacity;
};
/**
* @js NA
* @lua NA
*/
class ActionTintFrame:public ActionFrame
{

View File

@ -53,6 +53,10 @@ enum FrameEasingType
kframeEasingBackInOut,
};
/**
* @js NA
* @lua NA
*/
class ActionFrameEasing:public cocos2d::Object
{
protected:

View File

@ -37,21 +37,28 @@ public:
/**
* Default constructor
* @js ctor
*/
ActionManagerEx();
/**
* Default destructor
* @js NA
* @lua NA
*/
virtual ~ActionManagerEx();
/**
* Gets the static instance of ActionManager.
* @js getInstance
* @lua getInstance
*/
static ActionManagerEx* shareManager();
/**
* Purges ActionManager point.
* @js purge
* @lua destroyActionManager
*/
static void purgeActionManager();

View File

@ -31,6 +31,10 @@
namespace cocostudio {
/**
* @js NA
* @lua NA
*/
class ActionNode:public cocos2d::Object
{
public:

View File

@ -31,6 +31,10 @@
namespace cocostudio {
/**
* @js NA
* @lua NA
*/
class ActionObject:public cocos2d::Object
{
public:

View File

@ -89,6 +89,9 @@ public:
static Armature *create(const char *name, Bone *parentBone);
public:
/**
* @js ctor
*/
Armature();
/**
* @js NA
@ -159,8 +162,15 @@ public:
virtual void draw() override;
virtual const cocos2d::AffineTransform& getNodeToParentTransform() const override;
/**
* @js NA
* @lua NA
*/
inline void setBlendFunc(const cocos2d::BlendFunc &blendFunc) override { _blendFunc = blendFunc; }
/**
* @js NA
* @lua NA
*/
inline const cocos2d::BlendFunc &getBlendFunc(void) const override{ return _blendFunc; }
@ -199,13 +209,31 @@ public:
#if ENABLE_PHYSICS_BOX2D_DETECT
virtual b2Fixture *getShapeList();
/**
* @js NA
* @lua NA
*/
virtual void setBody(b2Body *body);
/**
* @js NA
* @lua NA
*/
virtual b2Body *getBody() const;
#elif ENABLE_PHYSICS_CHIPMUNK_DETECT
/**
* @js NA
* @lua NA
*/
virtual cpShape *getShapeList();
/**
* @js NA
* @lua NA
*/
virtual void setBody(cpBody *body);
/**
* @js NA
* @lua NA
*/
virtual cpBody *getBody() const;
#endif
@ -213,10 +241,15 @@ protected:
/*
* Used to create Bone internal
* @js NA
* @lua NA
*/
Bone *createBone(const char *boneName );
//! Update blend function
/**! Update blend function
* @js NA
* @lua NA
*/
void updateBlendType(BlendType blendType);
protected:

View File

@ -236,16 +236,22 @@ protected:
/**
* Update(float dt) will call this handler, you can handle your logic here
* @js NA
* @lua NA
*/
void updateHandler();
/**
* Update current key frame, and process auto stop, pause
* @js NA
* @lua NA
*/
void updateFrameData(float currentPercent);
/**
* Emit a frame event
* @js NA
* @lua NA
*/
void frameEvent(Bone *bone, const char *frameEventName, int originFrameIndex, int currentFrameIndex);

View File

@ -38,14 +38,27 @@ public:
* @js ctor
*/
BatchNode();
/**
* @ js NA
* @ lua NA
*/
~BatchNode();
/**
* @js NA
*/
virtual bool init() override;
virtual void addChild(cocos2d::Node *pChild) override;
virtual void addChild(cocos2d::Node *pChild, int zOrder) override;
virtual void addChild(cocos2d::Node *pChild, int zOrder, int tag) override;
virtual void removeChild(cocos2d::Node* child, bool cleanup) override;
/**
* @js NA
* @lua NA
*/
virtual void visit() override;
/**
* @js NA
*/
void draw() override;
virtual cocos2d::TextureAtlas *getTexureAtlasWithTexture(cocos2d::Texture2D *texture) const;

View File

@ -53,6 +53,9 @@ public:
static Bone *create(const char *name);
public:
/**
* @js ctor
*/
Bone();
/**
* @js NA
@ -173,12 +176,15 @@ public:
virtual Armature *getChildArmature() const;
virtual DisplayManager *getDisplayManager() const { return _displayManager; }
/**
* @lua NA
*/
virtual void setIgnoreMovementBoneData(bool ignore) { _ignoreMovementBoneData = ignore; }
virtual bool isIgnoreMovementBoneData() const { return _ignoreMovementBoneData; }
/*
* This function is deprecated, please use isIgnoreMovementBoneData()
* @lua NA
*/
CC_DEPRECATED_ATTRIBUTE virtual bool getIgnoreMovementBoneData() const { return isIgnoreMovementBoneData(); }

View File

@ -46,7 +46,10 @@ namespace cocostudio {
class Bone;
/**
* @js NA
* @lua NA
*/
class ColliderFilter
{
public:
@ -124,6 +127,8 @@ private:
/*
* @brief ContourSprite used to draw the contour of the display
* @js NA
* @lua NA
*/
class ColliderDetector : public cocos2d::Object
{

View File

@ -57,7 +57,9 @@ public:
float getFloat(const char *key) const;
bool getBool(const char *key) const;
const char* getCString(const char *key) const;
/**
* @js NA
*/
JsonDictionary* getDict() const;
private:

View File

@ -33,6 +33,9 @@ namespace cocostudio {
class ComController : public cocos2d::Component, public InputDelegate
{
public:
/**
* @js ctor
*/
ComController(void);
public:

View File

@ -32,6 +32,9 @@ namespace cocostudio {
class ComRender : public cocos2d::Component
{
protected:
/**
* @js ctor
*/
ComRender(void);
ComRender(cocos2d::Node *node, const char *comName);
/**

View File

@ -43,7 +43,10 @@ namespace tinyxml2
namespace cocostudio {
/**
* @js NA
* @lua NA
*/
class DataReaderHelper : cocos2d::Object
{
protected:

View File

@ -58,8 +58,10 @@ public: \
namespace cocostudio {
/**
* The base node include a lot of attributes.
*/
* The base node include a lot of attributes.
* @js NA
* @lua NA
*/
class BaseData : public cocos2d::Object
{
public:
@ -125,7 +127,10 @@ enum DisplayType
CS_DISPLAY_MAX
};
/**
* @js NA
* @lua NA
*/
class DisplayData : public cocos2d::Object
{
public:
@ -147,7 +152,10 @@ public:
};
/**
* @js NA
* @lua NA
*/
class SpriteDisplayData : public DisplayData
{
public:
@ -179,7 +187,10 @@ public:
BaseData skinData;
};
/**
* @js NA
* @lua NA
*/
class ArmatureDisplayData : public DisplayData
{
public:
@ -209,7 +220,10 @@ public:
};
/**
* @js NA
* @lua NA
*/
class ParticleDisplayData : public DisplayData
{
public:
@ -238,6 +252,8 @@ public:
* BoneData used to init a Bone.
* BoneData keeps a DisplayData list, a Bone can have many display to change.
* The display information saved in the DisplayData
* @js NA
* @lua NA
*/
class BoneData : public BaseData
{
@ -270,6 +286,8 @@ public:
* ArmatureData saved the Armature name and Bonedata needed for the CCBones in this Armature
* When we create a Armature, we need to get each Bone's BoneData as it's init information.
* So we can get a BoneData from the Dictionary saved in the ArmatureData.
* @js NA
* @lua NA
*/
class ArmatureData : public cocos2d::Object
{
@ -313,7 +331,10 @@ enum BlendType
BLEND_ERASE
};
/**
* @js NA
* @lua NA
*/
class FrameData : public BaseData
{
public:
@ -353,7 +374,10 @@ public:
std::string strSoundEffect;
};
/**
* @js NA
* @lua NA
*/
class MovementBoneData : public cocos2d::Object
{
public:
@ -382,7 +406,10 @@ public:
cocos2d::Array frameList;
};
/**
* @js NA
* @lua NA
*/
class MovementData : public cocos2d::Object
{
public:
@ -442,6 +469,8 @@ public:
* AnimationData include all movement infomation for the Armature
* The struct is AnimationData -> MovementData -> MovementBoneData -> FrameData
* -> MovementFrameData
* @js NA
* @lua NA
*/
class AnimationData : public cocos2d::Object
{
@ -482,6 +511,8 @@ struct ContourVertex2 : public cocos2d::Object
/*
* ContourData include a contour vertex information
* @js NA
* @lua NA
*/
class ContourData : public cocos2d::Object
{
@ -509,6 +540,8 @@ public:
/*
* TextureData include a texture's information
* @js NA
* @lua NA
*/
class TextureData : public cocos2d::Object
{

View File

@ -35,20 +35,16 @@ THE SOFTWARE.
#endif
namespace cocostudio {
/**
* @js NA
* @lua NA
*/
class DecorativeDisplay: public cocos2d::Object
{
public:
static DecorativeDisplay *create();
public:
/**
* @js ctor
*/
DecorativeDisplay(void);
/**
* @js NA
* @lua NA
*/
~DecorativeDisplay(void);
virtual bool init();

View File

@ -34,7 +34,10 @@ class Skin;
class Bone;
class DecorativeDisplay;
class DisplayData;
/**
* @js NA
* @lua NA
*/
class DisplayFactory
{
public:

View File

@ -33,21 +33,17 @@ namespace cocostudio {
class Bone;
//! DisplayManager manages Bone's display
/**! DisplayManager manages Bone's display
* @js NA
* @lua NA
*/
class DisplayManager : public cocos2d::Object
{
public:
static DisplayManager *create(Bone *bone);
public:
/**
* @js ctor
*/
DisplayManager();
/**
* @js NA
* @lua NA
*/
~DisplayManager();
bool init(Bone *bone);

View File

@ -29,96 +29,113 @@ THE SOFTWARE.
namespace cocostudio {
/**
* @lua NA
*/
class InputDelegate
{
protected:
/**
* @js NA
* @lua NA
* @js ctor
*/
InputDelegate(void);
/**
* @js NA
* @lua NA
*/
virtual ~InputDelegate(void);
public:
/**
* @js NA
* @lua NA
*/
virtual bool isTouchEnabled() const;
/**
* @js NA
* @lua NA
*/
virtual void setTouchEnabled(bool value);
/**
* @js NA
* @lua NA
*/
virtual bool isAccelerometerEnabled() const;
/**
* @js NA
* @lua NA
*/
virtual void setAccelerometerEnabled(bool value);
/**
* @js NA
* @lua NA
*/
virtual bool isKeypadEnabled() const;
/**
* @js NA
* @lua NA
*/
virtual void setKeypadEnabled(bool value);
/**
* @js NA
* @lua NA
*/
virtual void setTouchMode(cocos2d::Touch::DispatchMode mode);
/**
* @js NA
* @lua NA
*/
virtual cocos2d::Touch::DispatchMode getTouchMode() const;
/**
* @js NA
* @lua NA
*/
virtual void setTouchPriority(int priority);
/**
* @js NA
* @lua NA
*/
virtual int getTouchPriority() const;
/** @deprecated Please override onAcceleration */
/**
* @js NA
*/
CC_DEPRECATED_ATTRIBUTE virtual void didAccelerate(cocos2d::Acceleration* accelerationValue) final { CC_UNUSED_PARAM(accelerationValue); };
// Deprecated touch callbacks.
/**
* @js NA
*/
CC_DEPRECATED_ATTRIBUTE virtual bool ccTouchBegan(cocos2d::Touch *pTouch, cocos2d::Event *pEvent) final {CC_UNUSED_PARAM(pTouch); CC_UNUSED_PARAM(pEvent); return false;};
/**
* @js NA
*/
CC_DEPRECATED_ATTRIBUTE virtual void ccTouchMoved(cocos2d::Touch *pTouch, cocos2d::Event *pEvent) final {CC_UNUSED_PARAM(pTouch); CC_UNUSED_PARAM(pEvent);}
/**
* @js NA
*/
CC_DEPRECATED_ATTRIBUTE virtual void ccTouchEnded(cocos2d::Touch *pTouch, cocos2d::Event *pEvent) final {CC_UNUSED_PARAM(pTouch); CC_UNUSED_PARAM(pEvent);}
/**
* @js NA
*/
CC_DEPRECATED_ATTRIBUTE virtual void ccTouchCancelled(cocos2d::Touch *pTouch, cocos2d::Event *pEvent) final {CC_UNUSED_PARAM(pTouch); CC_UNUSED_PARAM(pEvent);}
/**
* @js NA
*/
CC_DEPRECATED_ATTRIBUTE virtual void ccTouchesBegan(cocos2d::Set *pTouches, cocos2d::Event *pEvent) final {CC_UNUSED_PARAM(pTouches); CC_UNUSED_PARAM(pEvent);}
/**
* @js NA
*/
CC_DEPRECATED_ATTRIBUTE virtual void ccTouchesMoved(cocos2d::Set *pTouches, cocos2d::Event *pEvent) final {CC_UNUSED_PARAM(pTouches); CC_UNUSED_PARAM(pEvent);}
/**
* @js NA
*/
CC_DEPRECATED_ATTRIBUTE virtual void ccTouchesEnded(cocos2d::Set *pTouches, cocos2d::Event *pEvent) final {CC_UNUSED_PARAM(pTouches); CC_UNUSED_PARAM(pEvent);}
/**
* @js NA
*/
CC_DEPRECATED_ATTRIBUTE virtual void ccTouchesCancelled(cocos2d::Set *pTouches, cocos2d::Event *pEvent) final {CC_UNUSED_PARAM(pTouches); CC_UNUSED_PARAM(pEvent);}
/**
* @js NA
*/
virtual void onAcceleration(cocos2d::Acceleration* acc, cocos2d::Event* event) {};
/**
* @js NA
*/
virtual void onKeyPressed(cocos2d::EventKeyboard::KeyCode keyCode, cocos2d::Event* event) {};
/**
* @js NA
*/
virtual void onKeyReleased(cocos2d::EventKeyboard::KeyCode keyCode, cocos2d::Event* event) {};
/**
* @js NA
*/
virtual bool onTouchBegan(cocos2d::Touch *touch, cocos2d::Event *event);
/**
* @js NA
*/
virtual void onTouchMoved(cocos2d::Touch *touch, cocos2d::Event *event);
/**
* @js NA
*/
virtual void onTouchEnded(cocos2d::Touch *touch, cocos2d::Event *event);
/**
* @js NA
*/
virtual void onTouchCancelled(cocos2d::Touch *touch, cocos2d::Event *event);
/**
* @js NA
*/
virtual void onTouchesBegan(const std::vector<cocos2d::Touch*>& touches, cocos2d::Event *event);
/**
* @js NA
*/
virtual void onTouchesMoved(const std::vector<cocos2d::Touch*>& touches, cocos2d::Event *event);
/**
* @js NA
*/
virtual void onTouchesEnded(const std::vector<cocos2d::Touch*>& touches, cocos2d::Event *event);
/**
* @js NA
*/
virtual void onTouchesCancelled(const std::vector<cocos2d::Touch*>& touches, cocos2d::Event *event);
protected:

View File

@ -46,18 +46,14 @@ enum AnimationType
};
/**
* @js NA
* @lua NA
*/
class ProcessBase : public cocos2d::Object
{
public:
/**
* @js ctor
*/
ProcessBase(void);
/**
* @js NA
* @lua NA
*/
virtual ~ProcessBase(void);
/**

View File

@ -34,14 +34,34 @@ namespace cocostudio {
class GUIReader : public cocos2d::Object
{
public:
/**
* @js ctor
*/
GUIReader();
/**
* @js NA
* @lua NA
*/
~GUIReader();
/**
* @js getInstance
* @lua getInstance
*/
static GUIReader* shareReader();
/**
* @js purge
*/
static void purgeGUIReader();
gui::UIWidget* widgetFromJsonFile(const char* fileName);
int getVersionInteger(const char* str);
/**
* @js NA
*/
void storeFileDesignSize(const char* fileName, const cocos2d::Size &size);
/**
* @js NA
*/
const cocos2d::Size getFileDesignSize(const char* fileName) const;
protected:
std::string m_strFilePath;

View File

@ -45,6 +45,10 @@ public:
public:
static SceneReader* getInstance();
/**
* @js purge
* @lua destroySceneReader
*/
void purgeSceneReader();
static const char* sceneReaderVersion();
cocos2d::Node* createNodeWithSceneFile(const char *pszFileName);

View File

@ -37,6 +37,9 @@ public:
static Skin *createWithSpriteFrameName(const char *pszSpriteFrameName);
static Skin *create(const char *pszFileName);
public:
/**
* @js ctor
*/
Skin();
virtual bool initWithSpriteFrameName(const std::string& spriteFrameName) override;
@ -47,8 +50,15 @@ public:
cocos2d::AffineTransform getNodeToWorldTransform() const override;
cocos2d::AffineTransform getNodeToWorldTransformAR() const;
/**
* @js NA
* @lua NA
*/
virtual void setSkinData(const BaseData &data);
/**
* @js NA
* @lua NA
*/
virtual const BaseData &getSkinData() const;
virtual void setBone(Bone *bone);

View File

@ -31,6 +31,10 @@ using namespace std;
namespace cocostudio {
/**
* @js NA
* @lua NA
*/
class SpriteFrameCacheHelper
{
public:
@ -48,14 +52,7 @@ public:
void addSpriteFrameFromFile(const char *plistPath, const char *imagePath);
private:
/**
* @js ctor
*/
SpriteFrameCacheHelper();
/**
* @js NA
* @lua NA
*/
~SpriteFrameCacheHelper();
static SpriteFrameCacheHelper *_spriteFrameCacheHelper;

View File

@ -32,6 +32,8 @@ namespace cocostudio {
/*
* use to calculate the matrix of node from parent node
* @js NA
* @lua NA
*/
class TransformHelp
{

View File

@ -34,6 +34,10 @@ namespace cocostudio {
class Bone;
class ArmatureAnimation;
/**
* @js NA
* @lua NA
*/
class Tween : public ProcessBase
{
public:
@ -43,14 +47,7 @@ public:
*/
static Tween *create(Bone *bone);
public:
/**
* @js ctor
*/
Tween(void);
/**
* @js NA
* @lua NA
*/
virtual ~Tween(void);
/**

View File

@ -79,7 +79,10 @@ enum TweenType
TWEEN_EASING_MAX = 10000
};
/**
* @js NA
* @lua NA
*/
class TweenFunction
{
public:

View File

@ -45,7 +45,10 @@ namespace cocostudio {
EDIC_TYPEARRAY,
EDIC_TYPEOBJECT
}DicItemType;
/**
* @js NA
* @lua NA
*/
class JsonDictionary
{
public:

View File

@ -31,7 +31,10 @@
#define DICTOOL DictionaryHelper::shareHelper()
namespace cocostudio {
/**
* @js NA
* @lua NA
*/
class DictionaryHelper
{
public:

View File

@ -29,20 +29,19 @@
namespace gui{
/**
* @js NA
* @lua NA
*/
class UIButton : public UIWidget
{
public:
/**
* Default constructor
* @js ctor
*/
UIButton();
/**
* Default destructor
* @js NA
* @lua NA
*/
virtual ~UIButton();

View File

@ -38,20 +38,19 @@ typedef enum
typedef void (cocos2d::Object::*SEL_SelectedStateEvent)(cocos2d::Object*,CheckBoxEventType);
#define checkboxselectedeventselector(_SELECTOR) (SEL_SelectedStateEvent)(&_SELECTOR)
/**
* @js NA
* @lua NA
*/
class UICheckBox : public UIWidget
{
public:
/**
* Default constructor
* @js ctor
*/
UICheckBox();
/**
* Default destructor
* @js NA
* @lua NA
*/
virtual ~UICheckBox();
@ -152,7 +151,10 @@ public:
//override "isFlipY" method of widget.
virtual bool isFlipY() override;
//override "onTouchEnded" method of widget.
/** override "onTouchEnded" method of widget.
* @js NA
* @lua NA
*/
virtual void onTouchEnded(const cocos2d::Point &touchPoint) override;
//override "getContentSize" method of widget.

View File

@ -27,10 +27,6 @@
namespace gui {
/**
* @js NA
* @lua NA
*/
class UIHelper
{
public:

View File

@ -29,20 +29,19 @@
namespace gui {
/**
* @js NA
* @lua NA
*/
class UIImageView : public UIWidget
{
public:
/**
* Default constructor
* @js ctor
*/
UIImageView();
/**
* Default destructor
* @js NA
* @lua NA
*/
virtual ~UIImageView();
@ -95,10 +94,16 @@ public:
//override "setAnchorPoint" method of widget.
virtual void setAnchorPoint(const cocos2d::Point &pt) override;
//override "onTouchBegan" method of widget.
/** override "onTouchBegan" method of widget.
* @js NA
* @lua NA
*/
virtual bool onTouchBegan(const cocos2d::Point &touchPoint) override;
//override "onTouchEnded" method of widget.
/** override "onTouchEnded" method of widget.
* @js NA
* @lua NA
*/
virtual void onTouchEnded(const cocos2d::Point &touchPoint) override;
//override "ignoreContentAdaptWithSize" method of widget.
@ -110,7 +115,14 @@ public:
virtual const char* getDescription() const override;
void setDoubleClickEnabled(bool able);
/**
* @js NA
* @lua NA
*/
void doubleClickEvent();
/**
* @js NA
*/
void checkDoubleClick(float dt);
virtual const cocos2d::Size& getContentSize() const override;
virtual cocos2d::Node* getVirtualRenderer() override;

View File

@ -29,7 +29,10 @@
#include "gui/UILayout.h"
namespace gui {
/**
* @js NA
* @lua NA
*/
class UIInputManager
{
public:

View File

@ -30,20 +30,19 @@
namespace gui {
/**
* @js NA
* @lua NA
*/
class UILabel : public UIWidget
{
public:
/**
* Default constructor
* @js ctor
*/
UILabel();
/**
* Default destructor
* @js NA
* @lua NA
*/
virtual ~UILabel();

View File

@ -29,20 +29,19 @@
namespace gui {
/**
* @js NA
* @lua NA
*/
class UILabelBMFont : public UIWidget
{
public:
/**
* Default constructor
* @js ctor
*/
UILabelBMFont();
/**
* Default destructor
* @js NA
* @lua NA
*/
virtual ~UILabelBMFont();

View File

@ -39,11 +39,14 @@ class UILayer : public cocos2d::Layer
public:
/**
* Default constructor
* @js ctor
*/
UILayer();
/**
* Default destructor
* @js NA
* @lua NA
*/
virtual ~UILayer();
@ -54,14 +57,36 @@ public:
//initializes state of uilayer.
virtual bool init() override;
/**
* @js NA
* @lua NA
*/
virtual void onEnter() override;
/**
* @js NA
* @lua NA
*/
virtual void onExit() override;
virtual void onEnterTransitionDidFinish() override;
/**
* @js NA
* @lua NA
*/
virtual bool onTouchBegan(cocos2d::Touch *pTouch, cocos2d::Event *pEvent);
/**
* @js NA
* @lua NA
*/
virtual void onTouchMoved(cocos2d::Touch *pTouch, cocos2d::Event *pEvent);
/**
* @js NA
* @lua NA
*/
virtual void onTouchEnded(cocos2d::Touch *pTouch, cocos2d::Event *pEvent);
/**
* @js NA
* @lua NA
*/
virtual void onTouchCancelled(cocos2d::Touch *pTouch, cocos2d::Event *pEvent);
/**
@ -109,6 +134,8 @@ public:
* UIInputManager is the touch manager of UILayer.
*
* @return UIInputManager.
* @js NA
* @lua NA
*/
UIInputManager* getInputManager();

View File

@ -44,21 +44,19 @@ typedef enum
LAYOUT_RELATIVE
}LayoutType;
/**
* @js NA
* @lua NA
*/
class UILayout : public UIWidget
{
public:
/**
* Default constructor
* @js ctor
*/
UILayout();
/**
* Default destructor
* @js NA
* @lua NA
*/
virtual ~UILayout();

View File

@ -35,20 +35,20 @@ typedef enum
LAYOUT_PARAMETER_LINEAR,
LAYOUT_PARAMETER_RELATIVE
}LayoutParameterType;
/**
* @js NA
* @lua NA
*/
class UILayoutParameter : public cocos2d::Object
{
public:
/**
* Default constructor
* @js ctor
*/
UILayoutParameter() : _margin(UIMargin()){_layoutParameterType = LAYOUT_PARAMETER_NONE;};
/**
* Default destructor
* @js NA
* @lua NA
*/
virtual ~UILayoutParameter(){};
@ -64,6 +64,8 @@ public:
* @see UIMargin
*
* @param margin
* @js NA
* @lua NA
*/
void setMargin(const UIMargin& margin);
@ -73,6 +75,8 @@ public:
* @see UIMargin
*
* @return const UIMargin&
* @js NA
* @lua NA
*/
const UIMargin& getMargin() const;

View File

@ -56,11 +56,14 @@ public:
/**
* Default constructor
* @js ctor
*/
UIListView();
/**
* Default destructor
* @js NA
* @lua NA
*/
virtual ~UIListView();

View File

@ -34,20 +34,20 @@ typedef enum
LoadingBarTypeLeft,
LoadingBarTypeRight
}LoadingBarType;
/**
* @js NA
* @lua NA
*/
class UILoadingBar : public UIWidget
{
public:
/**
* Default constructor
* @js ctor
*/
UILoadingBar();
/**
* Default destructor
* @js NA
* @lua NA
*/
virtual ~UILoadingBar();

View File

@ -49,11 +49,14 @@ class UIPageView : public UILayout , public UIScrollInterface
public:
/**
* Default constructor
* @js ctor
*/
UIPageView();
/**
* Default destructor
* @lua NA
* @js NA
*/
virtual ~UIPageView();
@ -127,16 +130,28 @@ public:
//override "onTouchBegan" method of widget.
/**override "onTouchBegan" method of widget.
* @js NA
* @lua NA
*/
virtual bool onTouchBegan(const cocos2d::Point &touchPoint) override;
//override "onTouchMoved" method of widget.
/**override "onTouchMoved" method of widget.
* @js NA
* @lua NA
*/
virtual void onTouchMoved(const cocos2d::Point &touchPoint) override;
//override "onTouchEnded" method of widget.
/**override "onTouchEnded" method of widget.
* @js NA
* @lua NA
*/
virtual void onTouchEnded(const cocos2d::Point &touchPoint) override;
//override "onTouchCancelled" method of widget.
/**override "onTouchCancelled" method of widget.
* @js NA
* @lua NA
*/
virtual void onTouchCancelled(const cocos2d::Point &touchPoint) override;
//override "update" method of widget.

View File

@ -30,9 +30,8 @@
namespace gui {
/**
* @js NA
* @lua NA
*/
* @js NA
*/
class UIRootWidget : public UILayout
{
public:
@ -43,6 +42,7 @@ public:
/**
* Default destructor
* @lua NA
*/
virtual ~UIRootWidget();

View File

@ -60,11 +60,14 @@ class UIScrollView : public UILayout , public UIScrollInterface
public:
/**
* Default constructor
* @js ctor
*/
UIScrollView();
/**
* Default destructor
* @lua NA
* @js NA
*/
virtual ~UIScrollView();

View File

@ -37,20 +37,19 @@ typedef enum
typedef void (cocos2d::Object::*SEL_SlidPercentChangedEvent)(cocos2d::Object*,SliderEventType);
#define sliderpercentchangedselector(_SELECTOR) (SEL_SlidPercentChangedEvent)(&_SELECTOR)
/**
* @js NA
* @lua NA
*/
class UISlider : public UIWidget
{
public:
/**
* Default constructor
* @js ctor
*/
UISlider();
/**
* Default destructor
* @js NA
* @lua NA
*/
virtual ~UISlider();

View File

@ -32,14 +32,18 @@ namespace gui {
/**
* @js NA
* @lua NA
*/
class UICCTextField: public cocos2d::TextFieldTTF, public cocos2d::TextFieldDelegate
{
public:
UICCTextField();
/**
* @lua NA
*/
~UICCTextField();
/**
* @lua NA
*/
virtual void onEnter();
// static
@ -97,13 +101,18 @@ typedef void (cocos2d::Object::*SEL_TextFieldEvent)(cocos2d::Object*, TextFiledE
#define textfieldeventselector(_SELECTOR) (SEL_TextFieldEvent)(&_SELECTOR)
/** class UITextField : public UIWidget
* @js NA
* @lua NA
*/
*/
class UITextField : public UIWidget
{
public:
/**
* @js ctor
*/
UITextField();
/**
* @js NA
* @lua NA
*/
virtual ~UITextField();
static UITextField* create();
virtual bool init() override;

View File

@ -72,20 +72,20 @@ typedef enum
typedef void (cocos2d::Object::*SEL_TouchEvent)(cocos2d::Object*,TouchEventType);
#define toucheventselector(_SELECTOR) (SEL_TouchEvent)(&_SELECTOR)
/**
* @js NA
* @lua NA
*/
class UIWidget : public cocos2d::Object
{
public:
/**
* Default constructor
* @js ctor
*/
UIWidget(void);
/**
* Default destructor
* @js NA
* @lua NA
*/
virtual ~UIWidget();
@ -613,6 +613,10 @@ public:
virtual void setCascadeOpacityEnabled(bool cascadeOpacityEnabled);
virtual bool isCascadeColorEnabled();
virtual void setCascadeColorEnabled(bool cascadeColorEnabled);
/**
* @js NA
* @lua NA
*/
void setBlendFunc(cocos2d::BlendFunc blendFunc);
//cocos action
@ -877,12 +881,22 @@ public:
virtual const char* getDescription() const;
UIWidget* clone();
/**
* @js NA
* @lua NA
*/
virtual void onEnter();
/**
* @js NA
* @lua NA
*/
virtual void onExit();
void updateSizeAndPosition();
/**
* @js NA
* @lua NA
*/
virtual Object* getUserObject() { return _userObject; }
/**
* @js NA
@ -899,6 +913,8 @@ public:
* The UserObject will be released in Node's destructure.
*
* @param userObject A user assigned Object
* @js NA
* @lua NA
*/
virtual void setUserObject(Object *userObject);
/*temp action*/

View File

@ -13,7 +13,7 @@ This project is based on the famous <A HREF="http://www.cocos2d-iphone.org">"coc
- twitter: http://twitter.com/cocos2dx/
- weibo: http://weibo.com/cocos2dx/
- wiki: http://wiki.cocos2d-x.org/
- show cases: http://www.cocos2d-x.org/projects/cocos2d-x/apps
- show cases: http://www.cocos2d-x.org/games
- <A HREF="http://www.cocos2d-x.org/projects/cocos2d-x/wiki/Tutorials">Tutorials of Cocos2dxSimpleGame</A>
- <A HREF="http://www.cocos2d-x.org/projects/cocos2d-x/wiki/Installation_and_First_run">Installation and First run</A>

View File

@ -1 +1 @@
3bc6566e5802e181c4baf91b8346473653c6d4ea
a245976c7421d00732cd7d3a1e18a09579794c70