Set all the items within a given menu, with the given itemName, to the given shader
| 1750 | |
| 1751 | // Set all the items within a given menu, with the given itemName, to the given shader |
| 1752 | void Menu_SetItemBackground(const menuDef_t *menu,const char *itemName, const char *background) |
| 1753 | { |
| 1754 | itemDef_t *item; |
| 1755 | int j, count; |
| 1756 | |
| 1757 | if (!menu) // No menu??? |
| 1758 | { |
| 1759 | return; |
| 1760 | } |
| 1761 | |
| 1762 | count = Menu_ItemsMatchingGroup( (menuDef_t *) menu, itemName); |
| 1763 | |
| 1764 | for (j = 0; j < count; j++) |
| 1765 | { |
| 1766 | item = Menu_GetMatchingItemByNumber( (menuDef_t *) menu, j, itemName); |
| 1767 | if (item != NULL) |
| 1768 | { |
| 1769 | // item->window.background = DC->registerShaderNoMip(background); |
| 1770 | item->window.background = ui.R_RegisterShaderNoMip(background); |
| 1771 | } |
| 1772 | } |
| 1773 | } |
| 1774 | |
| 1775 | // Set all the items within a given menu, with the given itemName, to the given text |
| 1776 | void Menu_SetItemText(const menuDef_t *menu,const char *itemName, const char *text) |
no test coverage detected