Merge pull request #8044 from andyque/fixWarnings

fix UI related warnings
This commit is contained in:
minggo 2014-09-15 11:34:22 +08:00
commit c28004866b
2 changed files with 3 additions and 3 deletions

View File

@ -364,7 +364,7 @@ void Button::onPressStateChangedToNormal()
{
_buttonNormalRenderer->stopAllActions();
_buttonClickedRenderer->stopAllActions();
Action *zoomAction = ScaleTo::create(0.05f, _normalTextureScaleXInSize, _normalTextureScaleYInSize);
Action *zoomAction = ScaleTo::create(ZOOM_ACTION_TIME_STEP, _normalTextureScaleXInSize, _normalTextureScaleYInSize);
_buttonNormalRenderer->runAction(zoomAction);
_buttonClickedRenderer->setScale(_pressedTextureScaleXInSize, _pressedTextureScaleYInSize);
@ -394,7 +394,7 @@ void Button::onPressStateChangedToPressed()
{
_buttonNormalRenderer->stopAllActions();
_buttonClickedRenderer->stopAllActions();
Action *zoomAction = ScaleTo::create(0.05f, _pressedTextureScaleXInSize + _zoomScale, _pressedTextureScaleYInSize + _zoomScale);
Action *zoomAction = ScaleTo::create(ZOOM_ACTION_TIME_STEP, _pressedTextureScaleXInSize + _zoomScale, _pressedTextureScaleYInSize + _zoomScale);
_buttonClickedRenderer->runAction(zoomAction);
_buttonNormalRenderer->setScale(_pressedTextureScaleXInSize + _zoomScale, _pressedTextureScaleYInSize + _zoomScale);

View File

@ -277,7 +277,7 @@ bool UITextFieldTest_LineWrap::init()
textField->ignoreContentAdaptWithSize(false);
((Label*)(textField->getVirtualRenderer()))->setLineBreakWithoutSpace(true);
textField->setContentSize(Size(240, 170));
textField->setText("input words here");
textField->setString("input words here");
textField->setTextHorizontalAlignment(TextHAlignment::CENTER);
textField->setTextVerticalAlignment(TextVAlignment::CENTER);
textField->setPosition(Vec2(widgetSize.width / 2.0f, widgetSize.height / 2.0f));