Update that sets default value of font name for ButtonReader, TextFieldReader, TextReader

This commit is contained in:
pipu 2014-12-10 15:46:58 +08:00
parent 6b6fe4129d
commit e81dca372a
3 changed files with 3 additions and 3 deletions

View File

@ -232,7 +232,7 @@ namespace cocostudio
button->setTitleFontSize(DICTOOL->getIntValue_json(options, P_FontSize,14));
button->setTitleFontName(DICTOOL->getStringValue_json(options, P_FontName));
button->setTitleFontName(DICTOOL->getStringValue_json(options, P_FontName, ""));

View File

@ -107,7 +107,7 @@ namespace cocostudio
textField->setFontSize(DICTOOL->getIntValue_json(options, P_FontSize,20));
textField->setFontName(DICTOOL->getStringValue_json(options, P_FontName));
textField->setFontName(DICTOOL->getStringValue_json(options, P_FontName, ""));
bool tsw = DICTOOL->checkObjectExist_json(options, P_TouchSizeWidth);
bool tsh = DICTOOL->checkObjectExist_json(options, P_TouchSizeHeight);

View File

@ -111,7 +111,7 @@ namespace cocostudio
label->setFontSize(DICTOOL->getIntValue_json(options, P_FontSize,20));
std::string fontName = DICTOOL->getStringValue_json(options, P_FontName);
std::string fontName = DICTOOL->getStringValue_json(options, P_FontName, "");
std::string fontFilePath = jsonPath.append(fontName);
if (FileUtils::getInstance()->isFileExist(fontFilePath))