Merge pull request #4658 from dumganhar/develop

Some warning fixes.
This commit is contained in:
James Chen 2013-12-25 00:09:33 -08:00
commit 00d16aadc5
5 changed files with 7 additions and 7 deletions

View File

@ -2053,7 +2053,7 @@ void Animate::startWithTarget(Node *target)
if (_animation->getRestoreOriginalFrame())
{
_origFrame = sprite->getDisplayFrame();
_origFrame = sprite->getSpriteFrame();
_origFrame->retain();
}
_nextFrame = 0;
@ -2064,7 +2064,7 @@ void Animate::stop(void)
{
if (_animation->getRestoreOriginalFrame() && _target)
{
static_cast<Sprite*>(_target)->setDisplayFrame(_origFrame);
static_cast<Sprite*>(_target)->setSpriteFrame(_origFrame);
}
ActionInterval::stop();
@ -2097,7 +2097,7 @@ void Animate::update(float t)
if( splitTime <= t ) {
AnimationFrame* frame = frames.at(i);
frameToDisplay = frame->getSpriteFrame();
static_cast<Sprite*>(_target)->setDisplayFrame(frameToDisplay);
static_cast<Sprite*>(_target)->setSpriteFrame(frameToDisplay);
const ValueMap& dict = frame->getUserInfo();
if ( !dict.empty() )

View File

@ -168,7 +168,7 @@ void Skeleton::draw () {
textureAtlas = regionTextureAtlas;
setFittedBlendingFunc(textureAtlas);
int quadCount = textureAtlas->getTotalQuads();
ssize_t quadCount = textureAtlas->getTotalQuads();
if (textureAtlas->getCapacity() == quadCount) {
textureAtlas->drawQuads();
textureAtlas->removeAllQuads();

View File

@ -65,7 +65,7 @@ void spSkeletonJson_dispose (spSkeletonJson* self) {
void _spSkeletonJson_setError (spSkeletonJson* self, Json* root, const char* value1, const char* value2) {
char message[256];
int length;
size_t length = 0;
FREE(self->error);
strcpy(message, value1);
length = strlen(value1);

View File

@ -62,7 +62,7 @@ char* _readFile (const char* path, int* length) {
if (!file) return 0;
fseek(file, 0, SEEK_END);
*length = ftell(file);
*length = (int)ftell(file);
fseek(file, 0, SEEK_SET);
data = MALLOC(char, *length);

View File

@ -39,6 +39,6 @@
#include <spine/CCSkeleton.h>
#include <spine/CCSkeletonAnimation.h>
void spRegionAttachment_updateQuad (spRegionAttachment* self, spSlot* slot, cocos2d::ccV3F_C4B_T2F_Quad* quad, bool premultiplied = false);
void spRegionAttachment_updateQuad (spRegionAttachment* self, spSlot* slot, cocos2d::V3F_C4B_T2F_Quad* quad, bool premultiplied = false);
#endif /* SPINE_COCOS2DX_H_ */