1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-11-25 22:42:04 +02:00

Replaced CIntObject::type bitfield with bool's. Added input blocking.

This commit is contained in:
Ivan Savenko
2023-07-03 19:24:12 +03:00
parent 48eb8ab54f
commit 8b61c0d59b
20 changed files with 77 additions and 54 deletions

View File

@@ -95,7 +95,7 @@ CMenuScreen::CMenuScreen(const JsonNode & configNode)
menuNameToEntry.push_back("credits");
tabs = std::make_shared<CTabbedInt>(std::bind(&CMenuScreen::createTab, this, _1));
tabs->type |= REDRAW_PARENT;
tabs->setRedrawParent(true);
}
std::shared_ptr<CIntObject> CMenuScreen::createTab(size_t index)
@@ -248,7 +248,7 @@ std::shared_ptr<CButton> CMenuEntry::createButton(CMenuScreen * parent, const Js
CMenuEntry::CMenuEntry(CMenuScreen * parent, const JsonNode & config)
{
OBJ_CONSTRUCTION_CAPTURING_ALL_NO_DISPOSE;
type |= REDRAW_PARENT;
setRedrawParent(true);
pos = parent->pos;
for(const JsonNode & node : config["images"].Vector())
@@ -258,7 +258,7 @@ CMenuEntry::CMenuEntry(CMenuScreen * parent, const JsonNode & config)
{
buttons.push_back(createButton(parent, node));
buttons.back()->hoverable = true;
buttons.back()->type |= REDRAW_PARENT;
buttons.back()->setRedrawParent(true);
}
}