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

Method maxContainerOffset

extensions/GUI/src/GUI/ScrollView/ScrollView.cpp:411–418  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

409}
410
411Vec2 ScrollView::maxContainerOffset()
412{
413 Point anchorPoint = _container->isIgnoreAnchorPointForPosition() ? Point::ZERO : _container->getAnchorPoint();
414 float contW = _container->getContentSize().width * _container->getScaleX();
415 float contH = _container->getContentSize().height * _container->getScaleY();
416
417 return Vec2(anchorPoint.x * contW, anchorPoint.y * contH);
418}
419
420Vec2 ScrollView::minContainerOffset()
421{

Callers 6

setContentOffsetMethod · 0.95
relocateContainerMethod · 0.95
deaccelerateScrollingMethod · 0.95
updateInsetMethod · 0.95
onMouseScrollMethod · 0.80

Calls 6

getAnchorPointMethod · 0.80
Vec2Function · 0.50
getContentSizeMethod · 0.45
getScaleXMethod · 0.45
getScaleYMethod · 0.45

Tested by 1

onMouseScrollMethod · 0.64