MCPcopy Create free account
hub / github.com/TorqueGameEngines/Torque3D / scrollCellVisible

Method scrollCellVisible

Engine/source/gui/core/guiArrayCtrl.cpp:175–185  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

173//-----------------------------------------------------------------------------
174
175void GuiArrayCtrl::scrollCellVisible(Point2I cell)
176{
177 //make sure we have a parent
178 //make sure we have a valid cell selected
179 GuiScrollCtrl *parent = dynamic_cast<GuiScrollCtrl*>(getParent());
180 if(!parent || cell.x < 0 || cell.y < 0)
181 return;
182
183 RectI cellBounds(cell.x * mCellSize.x, cell.y * mCellSize.y, mCellSize.x, mCellSize.y);
184 parent->scrollRectVisible(cellBounds);
185}
186
187//-----------------------------------------------------------------------------
188

Callers 3

onActionMethod · 0.80
onActionMethod · 0.80

Calls 1

scrollRectVisibleMethod · 0.80

Tested by

no test coverage detected