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

Method getSelectedItems

Engine/source/gui/controls/guiListBoxCtrl.cpp:468–480  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

466}
467
468void GuiListBoxCtrl::getSelectedItems( Vector<S32> &Items )
469{
470 // Clear our return vector
471 Items.clear();
472
473 // If there are no selected items, return an empty vector
474 if( mSelectedItems.empty() )
475 return;
476
477 for( S32 i = 0; i < mItems.size(); i++ )
478 if( mItems[i]->isSelected )
479 Items.push_back( i );
480}
481
482DefineEngineMethod( GuiListBoxCtrl, findItemText, S32, (const char* findText, bool bCaseSensitive), (false),
483 "@brief Returns index of item with matching text or -1 if none found.\n\n"

Callers 4

guiListBoxCtrl.cppFile · 0.80
getSelectedObjectListMethod · 0.80

Calls 4

clearMethod · 0.45
emptyMethod · 0.45
sizeMethod · 0.45
push_backMethod · 0.45

Tested by

no test coverage detected