Merge pull request #15466 from wefiends/spriteframe-clone

Copy polygonInfo when cloning SpriteFrame
This commit is contained in:
minggo 2016-04-21 09:49:00 +08:00
commit 481c55adb2
1 changed files with 1 additions and 0 deletions

View File

@ -137,6 +137,7 @@ SpriteFrame* SpriteFrame::clone() const
SpriteFrame *copy = new (std::nothrow) SpriteFrame();
copy->initWithTextureFilename(_textureFilename, _rectInPixels, _rotated, _offsetInPixels, _originalSizeInPixels);
copy->setTexture(_texture);
copy->setPolygonInfo(_polygonInfo);
copy->autorelease();
return copy;
}