mirror of https://github.com/axmolengine/axmol.git
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:
commit
581ef454eb
|
@ -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)) {
|
||||
|
|
|
@ -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)
|
||||
|
|
Loading…
Reference in New Issue