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

Method GetCurrentValue

Descent3/ConfigItem.cpp:303–312  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

301}
302
303bool ConfigItem::GetCurrentValue(int *currvalue) {
304 if (!m_bAlive)
305 return false;
306 if (m_iValueType != CIV_INT)
307 return false;
308 if (m_iType == CIT_LISTBOX) // we need to get the current index since it only gets updated on a double click
309 m_iCurrentValue = m_lbList[0]->GetSelectedIndex();
310 *currvalue = m_iCurrentValue;
311 return true;
312}
313
314bool ConfigItem::GetCurrentValue(bool *currvalue) {
315 if (!m_bAlive)

Callers

nothing calls this directly

Calls 1

GetSelectedIndexMethod · 0.45

Tested by

no test coverage detected