CComponentsForm: add member to get pointer to selected items

This commit is contained in:
2014-08-26 22:43:20 +02:00
committed by [CST] Focus
parent 0ab881b338
commit e1b9f0a184
2 changed files with 14 additions and 1 deletions

View File

@@ -491,3 +491,14 @@ int CComponentsForm::getSelectedItem()
return static_cast<int>(i);
return -1;
}
CComponentsItem* CComponentsForm::getSelectedItemObject()
{
int sel = getSelectedItem();
CComponentsItem* ret = NULL;
if (sel != -1)
ret = static_cast<CComponentsItem*>(this->getCCItem(sel));
return ret;
}