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

Method setupNormalTexture

core/ui/UIButton.cpp:299–318  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

297}
298
299void Button::setupNormalTexture(bool textureLoaded)
300{
301 _normalTextureSize = _buttonNormalRenderer->getContentSize();
302
303 this->updateChildrenDisplayedRGBA();
304
305 if (_unifySize)
306 {
307 if (!_scale9Enabled)
308 {
309 updateContentSizeWithTextureSize(this->getNormalSize());
310 }
311 }
312 else
313 {
314 updateContentSizeWithTextureSize(_normalTextureSize);
315 }
316 _normalTextureLoaded = textureLoaded;
317 _normalTextureAdaptDirty = true;
318}
319
320void Button::loadTextureNormal(SpriteFrame* normalSpriteFrame)
321{

Callers 1

loadTextureNormalMethod · 0.95

Calls 3

getNormalSizeMethod · 0.95
getContentSizeMethod · 0.45

Tested by

no test coverage detected