Quantcast
Channel: Cocos中文社区 - 最新主题
Viewing all articles
Browse latest Browse all 88737

找不到cclong的输出内容

$
0
0

@linqqhh 写道:



在DEBUG模式下用的CCLOG输出,但是点击按钮后没有CCLOG输出的内容.
代码:
bool HelloWorldLayer::init() {
if (!Layer::init()) {
return false;
}
Size size = Director::getInstance()->getVisibleSize();
Label* label = Label::createWithTTF("helloworld","fonts/Marker Felt.ttf",24);
label->setPosition(Vec2(size.width/2,size.height*3/4));
this->addChild(label);
auto sprite = Sprite::create("HelloWorld.png");
sprite->setPosition(Vec2(size.width/2,size.height/2));
this->addChild(sprite);
auto closeItem = MenuItemImage::create("CloseNormal.png","CloseSelected.png",CC_CALLBACK_1(HelloWorldLayer::menuCloseCallBack,this));
closeItem->setPosition(Vec2(400,100));
auto menu = Menu::create(closeItem,NULL);
menu->setPosition(Point::ZERO);
this->addChild(menu);
return true;
}
void HelloWorldLayer::menuCloseCallBack(Ref* pSender) {
CCLOG("menuCloseCallBack");
}

帖子: 1

参与者: 1

阅读整个主题


Viewing all articles
Browse latest Browse all 88737

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>