Merge pull request #7222 from minggo/warnings-fix

fix warnings
This commit is contained in:
minggo 2014-06-26 17:24:13 +08:00
commit 768eb4e1d0
3 changed files with 4 additions and 6 deletions

View File

@ -4,7 +4,6 @@ NS_CC_BEGIN
template <int componentSize>
void AnimationCurve<componentSize>::evaluate(float time, float* dst, EvaluateType type) const
{
int floatSize = sizeof(float);
if (_count == 1 || time <= _keytime[0])
{
memcpy(dst, _value, _componentSizeByte);

View File

@ -247,7 +247,6 @@ bool Bundle3D::loadAnimationData(const std::string& id, Animation3DData* animati
if ( bone.HasMember("keyframes"))
{
const rapidjson::Value& bone_keyframes = bone["keyframes"];
rapidjson::SizeType keyframe_size = bone_keyframes.Size();
for (rapidjson::SizeType j = 0; j < bone_keyframes.Size(); j++)
{
const rapidjson::Value& bone_keyframe = bone_keyframes[j];

View File

@ -111,8 +111,8 @@ void ActionTimelineTestLayer::onEnter()
// add title and subtitle
std::string str = title();
const char *pTitle = str.c_str();
LabelTTF *label = LabelTTF::create(pTitle, "Arial", 18);
const char *title = str.c_str();
auto label = Label::createWithSystemFont(title, "Arial", 18);
label->setColor(Color3B(0, 0, 0));
addChild(label, 1, 10000);
label->setPosition( Point(VisibleRect::center().x, VisibleRect::top().y - 30) );
@ -120,7 +120,7 @@ void ActionTimelineTestLayer::onEnter()
std::string strSubtitle = subtitle();
if( ! strSubtitle.empty() )
{
LabelTTF *l = LabelTTF::create(strSubtitle.c_str(), "Arial", 18);
auto l = Label::createWithSystemFont(strSubtitle.c_str(), "Arial", 18);
l->setColor(Color3B(0, 0, 0));
addChild(l, 1, 10001);
l->setPosition( Point(VisibleRect::center().x, VisibleRect::top().y - 60) );
@ -140,7 +140,7 @@ void ActionTimelineTestLayer::onEnter()
addChild(menu, 100);
setShaderProgram(ShaderCache::getInstance()->getProgram(GLProgram::SHADER_NAME_POSITION_TEXTURE_COLOR));
setGLProgram(ShaderCache::getInstance()->getGLProgram(GLProgram::SHADER_NAME_POSITION_TEXTURE_COLOR));
}
void ActionTimelineTestLayer::onExit()