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

Method findMenuItem

Engine/source/gui/editor/guiMenuBar.cpp:834–851  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

832}
833
834GuiMenuBar::MenuItem *GuiMenuBar::findMenuItem(Menu *menu, const char *menuItem)
835{
836 if(dIsdigit(menuItem[0]))
837 {
838 U32 id = dAtoi(menuItem);
839 for(MenuItem *walk = menu->firstMenuItem; walk; walk = walk->nextMenuItem)
840 if(id == walk->id)
841 return walk;
842 return NULL;
843 }
844 else
845 {
846 for(MenuItem *walk = menu->firstMenuItem; walk; walk = walk->nextMenuItem)
847 if(!dStricmp(menuItem, walk->text))
848 return walk;
849 return NULL;
850 }
851}
852
853void GuiMenuBar::removeMenu(Menu *menu)
854{

Callers 1

guiMenuBar.cppFile · 0.80

Calls 3

dIsdigitFunction · 0.85
dStricmpFunction · 0.85
dAtoiFunction · 0.50

Tested by

no test coverage detected