DisplayManager manages Bone's display. More...
#include <CCDisplayManager.h>
Public Member Functions | |
DisplayManager () | |
ctor () | |
DisplayManager () | |
~DisplayManager () | |
bool | init (Bone *bone) |
local | init ( local bone) |
virtual void | initDisplayList (BoneData *boneData) |
Use BoneData to init the display list. More... | |
local | initDisplayList ( local boneData) |
Use BoneData to init the display list. More... | |
void | addDisplay (DisplayData *displayData, int index) |
Add display and use _DisplayData init the display. More... | |
var | addDisplay ( var displayData, var index) |
Add display and use _DisplayData init the display. More... | |
local | addDisplay ( local displayData, local index) |
Add display and use _DisplayData init the display. More... | |
void | addDisplay (Node *display, int index) |
void | removeDisplay (int index) |
var | removeDisplay ( var index) |
local | removeDisplay ( local index) |
Array * | getDecorativeDisplayList () |
var | getDecorativeDisplayList () |
local | getDecorativeDisplayList () |
void | changeDisplayByIndex (int index, bool force) |
Change display by index. More... | |
Node * | getDisplayRenderNode () |
int | getCurrentDisplayIndex () |
var | getCurrentDisplayIndex () |
local | getCurrentDisplayIndex () |
virtual void | setCurrentDecorativeDisplay (DecorativeDisplay *decoDisplay) |
var | setCurrentDecorativeDisplay ( var decoDisplay) |
local | setCurrentDecorativeDisplay ( local decoDisplay) |
virtual DecorativeDisplay * | getCurrentDecorativeDisplay () |
local | getCurrentDecorativeDisplay () |
virtual DecorativeDisplay * | getDecorativeDisplayByIndex (int index) |
local | getDecorativeDisplayByIndex ( local index) |
virtual void | setVisible (bool visible) |
Sets whether the display is visible The default value is true, a node is default to visible. More... | |
var | setVisible ( var visible) |
Sets whether the display is visible The default value is true, a node is default to visible. More... | |
local | setVisible ( local visible) |
Sets whether the display is visible The default value is true, a node is default to visible. More... | |
virtual bool | isVisible () |
Determines if the display is visible. More... | |
local | isVisible () |
Determines if the display is visible. More... | |
Size | getContentSize () |
Rect | getBoundingBox () |
var | getBoundingBox () |
local | getBoundingBox () |
Point | getAnchorPoint () |
var | getAnchorPoint () |
local | getAnchorPoint () |
Point | getAnchorPointInPoints () |
virtual bool | containPoint (Point &_point) |
Check if the position is inside the bone. More... | |
var | containPoint ( var _point) |
Check if the position is inside the bone. More... | |
local | containPoint ( local _point) |
Check if the position is inside the bone. More... | |
virtual bool | containPoint (float x, float y) |
Check if the position is inside the bone. More... | |
var | containPoint ( var x, var y) |
Check if the position is inside the bone. More... | |
local | containPoint ( local x, local y) |
Check if the position is inside the bone. More... | |
Public Member Functions inherited from Object | |
Object () | |
Constructor. More... | |
virtual | ~Object () |
void | release () |
Release the ownership immediately. More... | |
void | retain () |
Retains the ownership. More... | |
Object * | autorelease () |
Release the ownership sometime soon automatically. More... | |
bool | isSingleReference () const |
Returns a boolean value that indicates whether there is only one reference to the object. More... | |
unsigned int | retainCount () const |
Returns the object's current reference count. More... | |
virtual bool | isEqual (const Object *object) |
Returns a boolean value that indicates whether this object and a given object are equal. More... | |
virtual void | acceptVisitor (DataVisitor &visitor) |
virtual void | update (float dt) |
Static Public Member Functions | |
static DisplayManager * | create (Bone *bone) |
local | create ( local bone) |
Public Attributes | |
virtual bool getForceChangeDisplay(void)\n\n public bool | _visible |
getForceChangeDisplay More... | |
Bone * | _bone |
var | _bone |
local | _bone |
Public Attributes inherited from Object | |
unsigned int | _ID |
object id, ScriptSupport need public _ID More... | |
int | _luaID |
Lua reference id. More... | |
Protected Attributes | |
Array * | _decoDisplayList |
Node * | _displayRenderNode |
Display render node. More... | |
var | _displayRenderNode |
Display render node. More... | |
local | _displayRenderNode |
Display render node. More... | |
DecorativeDisplay * | _currentDecoDisplay |
Include current display information, like contour sprite, etc. More... | |
var | _currentDecoDisplay |
Include current display information, like contour sprite, etc. More... | |
local | _currentDecoDisplay |
Include current display information, like contour sprite, etc. More... | |
int | _displayIndex |
Current display index. More... | |
bool | _forceChangeDisplay |
Protected Attributes inherited from Object | |
unsigned int | _reference |
count of references More... | |
var | _reference |
count of references More... | |
local | _reference |
count of references More... | |
unsigned int | _autoReleaseCount |
count of autorelease More... | |
var | _autoReleaseCount |
count of autorelease More... | |
local | _autoReleaseCount |
count of autorelease More... | |
DisplayManager manages Bone's display.
DisplayManager | ( | ) |
var ctor | ( | ) |
local DisplayManager | ( | ) |
~DisplayManager | ( | ) |
void addDisplay | ( | DisplayData * | displayData, |
int | index | ||
) |
Add display and use _DisplayData init the display.
If index already have a display, then replace it. If index is current display index, then also change display to _index
displayData | it include the display information, like DisplayType. If you want to create a sprite display, then create a SpriteDisplayData param |
index | the index of the display you want to replace or add to -1 : append display from back |
var addDisplay | ( | var | displayData, |
var | index | ||
) |
Add display and use _DisplayData init the display.
If index already have a display, then replace it. If index is current display index, then also change display to _index
displayData | it include the display information, like DisplayType. If you want to create a sprite display, then create a SpriteDisplayData param |
index | the index of the display you want to replace or add to -1 : append display from back |
local addDisplay | ( | local | displayData, |
local | index | ||
) |
Add display and use _DisplayData init the display.
If index already have a display, then replace it. If index is current display index, then also change display to _index
displayData | it include the display information, like DisplayType. If you want to create a sprite display, then create a SpriteDisplayData param |
index | the index of the display you want to replace or add to -1 : append display from back |
void addDisplay | ( | Node * | display, |
int | index | ||
) |
var addDisplay | ( | var | display, |
var | index | ||
) |
local addDisplay | ( | local | display, |
local | index | ||
) |
void changeDisplayByIndex | ( | int | index, |
bool | force | ||
) |
Change display by index.
You can just use this method to change display in the display list. The display list is just used for this bone, and it is the displays you may use in every frame.
Note : if index is the same with prev index, the method will not effect
index | The index of the display you want to change |
force | If true, then force change display to specified display, or current display will set to display index edit in the flash every key frame. |
var changeDisplayByIndex | ( | var | index, |
var | force | ||
) |
Change display by index.
You can just use this method to change display in the display list. The display list is just used for this bone, and it is the displays you may use in every frame.
Note : if index is the same with prev index, the method will not effect
index | The index of the display you want to change |
force | If true, then force change display to specified display, or current display will set to display index edit in the flash every key frame. |
local changeDisplayByIndex | ( | local | index, |
local | force | ||
) |
Change display by index.
You can just use this method to change display in the display list. The display list is just used for this bone, and it is the displays you may use in every frame.
Note : if index is the same with prev index, the method will not effect
index | The index of the display you want to change |
force | If true, then force change display to specified display, or current display will set to display index edit in the flash every key frame. |
|
virtual |
Check if the position is inside the bone.
|
virtual |
Check if the position is inside the bone.
|
virtual |
Check if the position is inside the bone.
|
virtual |
Check if the position is inside the bone.
|
virtual |
Check if the position is inside the bone.
|
virtual |
Check if the position is inside the bone.
|
static |
|
static |
|
static |
Point getAnchorPoint | ( | ) |
var getAnchorPoint | ( | ) |
local getAnchorPoint | ( | ) |
Point getAnchorPointInPoints | ( | ) |
var getAnchorPointInPoints | ( | ) |
local getAnchorPointInPoints | ( | ) |
Rect getBoundingBox | ( | ) |
var getBoundingBox | ( | ) |
local getBoundingBox | ( | ) |
Size getContentSize | ( | ) |
var getContentSize | ( | ) |
local getContentSize | ( | ) |
|
virtual |
|
virtual |
|
virtual |
int getCurrentDisplayIndex | ( | ) |
var getCurrentDisplayIndex | ( | ) |
local getCurrentDisplayIndex | ( | ) |
|
virtual |
|
virtual |
|
virtual |
Array* getDecorativeDisplayList | ( | ) |
var getDecorativeDisplayList | ( | ) |
local getDecorativeDisplayList | ( | ) |
Node* getDisplayRenderNode | ( | ) |
var getDisplayRenderNode | ( | ) |
local getDisplayRenderNode | ( | ) |
bool init | ( | Bone * | bone) |
var init | ( | var | bone) |
local init | ( | local | bone) |
|
virtual |
|
virtual |
|
virtual |
|
virtual |
Determines if the display is visible.
|
virtual |
Determines if the display is visible.
|
virtual |
Determines if the display is visible.
void removeDisplay | ( | int | index) |
var removeDisplay | ( | var | index) |
local removeDisplay | ( | local | index) |
|
virtual |
|
virtual |
|
virtual |
|
virtual |
Sets whether the display is visible The default value is true, a node is default to visible.
visible | true if the node is visible, false if the node is hidden. |
|
virtual |
Sets whether the display is visible The default value is true, a node is default to visible.
visible | true if the node is visible, false if the node is hidden. |
|
virtual |
Sets whether the display is visible The default value is true, a node is default to visible.
visible | true if the node is visible, false if the node is hidden. |
Bone* _bone |
var _bone |
local _bone |
|
protected |
Include current display information, like contour sprite, etc.
|
protected |
Include current display information, like contour sprite, etc.
|
protected |
Include current display information, like contour sprite, etc.
|
protected |
|
protected |
Current display index.
|
protected |
Current display index.
|
protected |
Current display index.
|
protected |
Display render node.
|
protected |
Display render node.
|
protected |
Display render node.
|
protected |
|
protected |
|
protected |
virtual bool getForceChangeDisplay (void)\n \n public bool _visible |
getForceChangeDisplay
setForceChangeDisplay Whether of not the bone is visible. Default is true
var _visible |
getForceChangeDisplay
setForceChangeDisplay Whether of not the bone is visible. Default is true
local _visible |
getForceChangeDisplay
setForceChangeDisplay Whether of not the bone is visible. Default is true