mirror of
https://github.com/cocos/cocos4.git
synced 2026-11-21 08:02:39 +08:00
Merge pull request #411 from zilongshanren/improve-jsb-label-content-size
fix label size in EditBox
This commit is contained in:
@@ -1251,9 +1251,10 @@ void Label::createSpriteForSystemFont(const FontDefinition& fontDef)
|
||||
auto newSize = _textSprite->getContentSize();
|
||||
if(_overflow == Overflow::RESIZE_HEIGHT) {
|
||||
this->setContentSize(Size(_contentSize.width, newSize.height));
|
||||
} else if (_overflow == Overflow::NONE) {
|
||||
} else {
|
||||
this->setContentSize(newSize);
|
||||
}
|
||||
|
||||
texture->release();
|
||||
if (_blendFuncDirty)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user