MCPcopy Create free account
hub / github.com/JACoders/OpenJK / Menu_ItemDisable

Function Menu_ItemDisable

code/ui/ui_shared.cpp:1960–1977  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1958}
1959
1960void Menu_ItemDisable(menuDef_t *menu, const char *name, qboolean disableFlag)
1961{
1962 int j,count;
1963 itemDef_t *itemFound;
1964
1965 count = Menu_ItemsMatchingGroup(menu, name);
1966 // Loop through all items that have this name
1967 for (j = 0; j < count; j++)
1968 {
1969 itemFound = Menu_GetMatchingItemByNumber( menu, j, name);
1970 if (itemFound != NULL)
1971 {
1972 itemFound->disabled = disableFlag;
1973 // Just in case it had focus
1974 itemFound->window.flags &= ~WINDOW_MOUSEOVER;
1975 }
1976 }
1977}
1978
1979/*
1980=================

Callers

nothing calls this directly

Calls 2

Menu_ItemsMatchingGroupFunction · 0.70

Tested by

no test coverage detected