MCPcopy Create free account
hub / github.com/MyGUI/mygui / getItemById

Method getItemById

MyGUIEngine/src/MyGUI_MenuControl.cpp:634–642  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

632 }
633
634 MenuItem* MenuControl::getItemById(std::string_view _id) const
635 {
636 for (const auto& info : mItemsInfo)
637 {
638 if (info.id == _id)
639 return info.item;
640 }
641 MYGUI_EXCEPT("item id (" << _id << ") not found, source 'MenuControl::getItemById'");
642 }
643
644 size_t MenuControl::getItemIndexById(std::string_view _id) const
645 {

Calls

no outgoing calls

Tested by

no test coverage detected