MCPcopy Create free account
hub / github.com/axmolengine/axmol / updateContentSize

Method updateContentSize

core/ui/UIButton.cpp:593–614  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

591}
592
593void Button::updateContentSize()
594{
595 if (_unifySize)
596 {
597 if (_scale9Enabled)
598 {
599 ProtectedNode::setContentSize(_customSize);
600 }
601 else
602 {
603 Vec2 s = getNormalSize();
604 ProtectedNode::setContentSize(s);
605 }
606 onSizeChanged();
607 return;
608 }
609
610 if (_ignoreSize)
611 {
612 this->setContentSize(getVirtualRendererSize());
613 }
614}
615
616void Button::onSizeChanged()
617{

Callers 1

Calls 1

setContentSizeMethod · 0.45

Tested by

no test coverage detected