MCPcopy Create free account
hub / github.com/DescentDevelopers/Descent3 / SetStateItem

Method SetStateItem

ui/UIButton.cpp:165–173  ·  view source on GitHub ↗

sets the background bitmap for a specified button state

Source from the content-addressed store, hash-verified

163
164// sets the background bitmap for a specified button state
165void UIButton::SetStateItem(int state, UIItem *item) {
166 ASSERT(state < UI_BTS_NUM);
167 if (m_Items[state]) {
168 delete m_Items[state];
169 m_Items[state] = NULL;
170 }
171 if (item)
172 m_Items[state] = item->CopyUIItem();
173}
174
175// sets the background color for a specified button state
176void UIButton::SetColor(int state, ddgr_color col) {

Callers 1

AddMethod · 0.80

Calls 1

CopyUIItemMethod · 0.45

Tested by

no test coverage detected