From c501aa2dec85a9670a22e2ac9374408f6e916026 Mon Sep 17 00:00:00 2001 From: andyque Date: Thu, 3 Apr 2014 17:42:04 +0800 Subject: [PATCH] issue #4636. replace __String with StringUtils::format --- .../CocoStudioGUITest/UIPageViewTest/UIPageViewTest.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/tests/cpp-tests/Classes/ExtensionsTest/CocoStudioGUITest/UIPageViewTest/UIPageViewTest.cpp b/tests/cpp-tests/Classes/ExtensionsTest/CocoStudioGUITest/UIPageViewTest/UIPageViewTest.cpp index 2680ef031c..01d9e7d41c 100644 --- a/tests/cpp-tests/Classes/ExtensionsTest/CocoStudioGUITest/UIPageViewTest/UIPageViewTest.cpp +++ b/tests/cpp-tests/Classes/ExtensionsTest/CocoStudioGUITest/UIPageViewTest/UIPageViewTest.cpp @@ -58,8 +58,7 @@ bool UIPageViewTest::init() imageView->setPosition(Point(layout->getSize().width / 2.0f, layout->getSize().height / 2.0f)); layout->addChild(imageView); - __String *textContent = __String::createWithFormat("page %d", (i + 1)); - Text* label = Text::create(textContent->getCString(), "fonts/Marker Felt.ttf", 30); + Text* label = Text::create(StringUtils::format("page %d",(i+1)), "fonts/Marker Felt.ttf", 30); label->setColor(Color3B(192, 192, 192)); label->setPosition(Point(layout->getSize().width / 2.0f, layout->getSize().height / 2.0f)); layout->addChild(label);