Merge pull request #6047 from samuele3hu/develop_test

Replace `LabelTTF` and `LabelBMFont` with `Label` for cocosbuild proxy and fix the error that  ControlSwitch:create raised.
This commit is contained in:
James Chen 2014-03-28 18:04:12 +08:00
commit 581ef454eb
2 changed files with 4 additions and 8 deletions

View File

@ -57,12 +57,8 @@ const char* CCBProxy::getNodeTypeName(Node* pNode)
return NULL;
}
if (NULL != dynamic_cast<LabelTTF*>(pNode)) {
return "cc.LabelTTF";
}
if (NULL != dynamic_cast<LabelBMFont*>(pNode)) {
return "cc.LabelBMFont";
if (NULL != dynamic_cast<Label*>(pNode)) {
return "cc.Label";
}
if (NULL != dynamic_cast<Sprite*>(pNode)) {

View File

@ -511,8 +511,8 @@ local function runCCControlTest()
cc.Sprite:create("extensions/switch-on.png"),
cc.Sprite:create("extensions/switch-off.png"),
cc.Sprite:create("extensions/switch-thumb.png"),
cc.LabelTTF:create("On", "Arial-BoldMT", 16),
cc.LabelTTF:create("Off", "Arial-BoldMT", 16)
cc.Label:create("On", "Arial-BoldMT", 16),
cc.Label:create("Off", "Arial-BoldMT", 16)
)
pSwitchControl:setPosition(cc.p (dLayer_width + 10 + pSwitchControl:getContentSize().width / 2, 0))
pNode:addChild(pSwitchControl)