MCPcopy Create free account
hub / github.com/GarageGames/Torque3D / setEntryActive

Method setEntryActive

Engine/source/gui/controls/guiTextListCtrl.cpp:301–318  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

299}
300
301void GuiTextListCtrl::setEntryActive(U32 id, bool active)
302{
303 S32 index = findEntryById( id );
304 if ( index == -1 )
305 return;
306
307 if ( mList[index].active != active )
308 {
309 mList[index].active = active;
310
311 // You can't have an inactive entry selected...
312 if ( !active && mSelectedCell.y >= 0 && mSelectedCell.y < mList.size()
313 && mList[mSelectedCell.y].id == id )
314 setSelectedCell( Point2I( -1, -1 ) );
315
316 setUpdate();
317 }
318}
319
320S32 GuiTextListCtrl::findEntryById(U32 id)
321{

Callers 4

showPopupMethod · 0.80
onActionMethod · 0.80
onSubmenuActionMethod · 0.80

Calls 2

Point2IClass · 0.50
sizeMethod · 0.45

Tested by

no test coverage detected