diff --git a/Source/UI/Item/UIEquipmentPropertiesWnd.cpp b/Source/UI/Item/UIEquipmentPropertiesWnd.cpp index 30f0f36d6..86f291b4c 100644 --- a/Source/UI/Item/UIEquipmentPropertiesWnd.cpp +++ b/Source/UI/Item/UIEquipmentPropertiesWnd.cpp @@ -554,7 +554,11 @@ void CUIEquipmentPropertiesWnd::Slot15(int width, int height) { this->tabs = new CUITab(); this->tabs->SetSize(18, 265); this->tabs->Move(3, 18); - this->tabs->SetOnChange([this](CUITabButton* button) { this->OnChangeTab(button); }); + { + CUITab* tabs = this->tabs; + const std::function handler = [this](CUITabButton* button) { this->OnChangeTab(button); }; + tabs->onChange = handler; + } this->AddChild(this->tabs); CUITabButton* allButton = new CUITabButton();