diff --git a/cocos/editor-support/cocostudio/ActionTimeline/CCNodeReader.cpp b/cocos/editor-support/cocostudio/ActionTimeline/CCNodeReader.cpp index 794e44cbce..3078dcd54a 100644 --- a/cocos/editor-support/cocostudio/ActionTimeline/CCNodeReader.cpp +++ b/cocos/editor-support/cocostudio/ActionTimeline/CCNodeReader.cpp @@ -45,6 +45,8 @@ static const char* ClassName_Button = "Button"; static const char* ClassName_CheckBox = "CheckBox"; static const char* ClassName_ImageView = "ImageView"; static const char* ClassName_TextAtlas = "TextAtlas"; +static const char* ClassName_LabelAtlas = "LabelAtlas"; +static const char* ClassName_LabelBMFont= "LabelBMFont"; static const char* ClassName_TextBMFont = "TextBMFont"; static const char* ClassName_Text = "Text"; static const char* ClassName_LoadingBar = "LoadingBar"; @@ -132,7 +134,8 @@ void NodeReader::init() _funcs.insert(Pair(ClassName_SubGraph, std::bind(&NodeReader::loadSubGraph, this, _1))); _funcs.insert(Pair(ClassName_Sprite, std::bind(&NodeReader::loadSprite, this, _1))); _funcs.insert(Pair(ClassName_Particle, std::bind(&NodeReader::loadParticle, this, _1))); - + _funcs.insert(Pair(ClassName_LabelAtlas,std::bind(&NodeReader::loadWidget, this, _1))); + _funcs.insert(Pair(ClassName_LabelBMFont,std::bind(&NodeReader::loadWidget, this, _1))); _funcs.insert(Pair(ClassName_Panel, std::bind(&NodeReader::loadWidget, this, _1))); _funcs.insert(Pair(ClassName_Button, std::bind(&NodeReader::loadWidget, this, _1))); _funcs.insert(Pair(ClassName_CheckBox, std::bind(&NodeReader::loadWidget, this, _1))); diff --git a/cocos/ui/UITextField.cpp b/cocos/ui/UITextField.cpp index 1cbbd901c0..4363b90f3f 100644 --- a/cocos/ui/UITextField.cpp +++ b/cocos/ui/UITextField.cpp @@ -622,11 +622,14 @@ bool TextField::isPasswordEnabled()const void TextField::setPasswordStyleText(const char *styleText) { - _textFieldRenderer->setPasswordStyleText(styleText); + if (nullptr != styleText) { + _textFieldRenderer->setPasswordStyleText(styleText); + _passwordStyleText = styleText; + + setText(getStringValue()); + } - _passwordStyleText = styleText; - - setText(getStringValue()); + } const char* TextField::getPasswordStyleText()const