1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-06-15 00:05:02 +02:00

Restore previously disabled functionality

This commit is contained in:
Ivan Savenko
2024-02-29 15:52:11 +02:00
parent ddb2acb9c2
commit 22f23ba6f8
6 changed files with 39 additions and 14 deletions

View File

@ -168,11 +168,9 @@ ComboBox::ComboBox(Point position, const AnimationPath & defName, const std::pai
void ComboBox::setItem(const void * item)
{
// TODO:
//auto w = std::dynamic_pointer_cast<CLabel>(overlay);
//if( w && getItemText)
// setTextOverlay(getItemText(0, item), w->font, w->color);
auto w = std::dynamic_pointer_cast<CLabel>(getOverlay());
if( w && getItemText)
setTextOverlay(getItemText(0, item), w->font, w->color);
if(onSetItem)
onSetItem(item);