mirror of
https://github.com/vcmi/vcmi.git
synced 2025-11-29 23:07:48 +02:00
Remove excessive totalRedraw's
This commit is contained in:
@@ -583,6 +583,7 @@ void CPlayerInterface::heroInGarrisonChange(const CGTownInstance *town)
|
|||||||
castleInt->garr->setArmy(town->visitingHero, 1);
|
castleInt->garr->setArmy(town->visitingHero, 1);
|
||||||
castleInt->garr->recreateSlots();
|
castleInt->garr->recreateSlots();
|
||||||
castleInt->heroes->update();
|
castleInt->heroes->update();
|
||||||
|
castleInt->redraw();
|
||||||
}
|
}
|
||||||
for (auto isa : GH.listInt)
|
for (auto isa : GH.listInt)
|
||||||
{
|
{
|
||||||
@@ -591,9 +592,9 @@ void CPlayerInterface::heroInGarrisonChange(const CGTownInstance *town)
|
|||||||
{
|
{
|
||||||
ki->townChanged(town);
|
ki->townChanged(town);
|
||||||
ki->updateGarrisons();
|
ki->updateGarrisons();
|
||||||
|
ki->redraw();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
GH.totalRedraw();
|
|
||||||
}
|
}
|
||||||
void CPlayerInterface::heroVisitsTown(const CGHeroInstance* hero, const CGTownInstance * town)
|
void CPlayerInterface::heroVisitsTown(const CGHeroInstance* hero, const CGTownInstance * town)
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -1404,6 +1404,7 @@ void CAdvMapInt::aiTurnStarted()
|
|||||||
mapAudio->onEnemyTurnStarted();
|
mapAudio->onEnemyTurnStarted();
|
||||||
adventureInt->minimap->setAIRadar(true);
|
adventureInt->minimap->setAIRadar(true);
|
||||||
adventureInt->infoBar->startEnemyTurn(LOCPLINT->cb->getCurrentPlayer());
|
adventureInt->infoBar->startEnemyTurn(LOCPLINT->cb->getCurrentPlayer());
|
||||||
|
adventureInt->minimap->showAll(screen);//force refresh on inactive object
|
||||||
adventureInt->infoBar->showAll(screen);//force refresh on inactive object
|
adventureInt->infoBar->showAll(screen);//force refresh on inactive object
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -77,7 +77,7 @@ void CList::CListItem::onSelect(bool on)
|
|||||||
if(on)
|
if(on)
|
||||||
selection = genSelection();
|
selection = genSelection();
|
||||||
select(on);
|
select(on);
|
||||||
GH.totalRedraw();
|
redraw();
|
||||||
}
|
}
|
||||||
|
|
||||||
CList::CList(int Size, Point position, std::string btnUp, std::string btnDown, size_t listAmount, int helpUp, int helpDown, CListBox::CreateFunc create)
|
CList::CList(int Size, Point position, std::string btnUp, std::string btnDown, size_t listAmount, int helpUp, int helpDown, CListBox::CreateFunc create)
|
||||||
|
|||||||
@@ -222,10 +222,7 @@ void CMinimap::setAIRadar(bool on)
|
|||||||
aiShield->disable();
|
aiShield->disable();
|
||||||
update();
|
update();
|
||||||
}
|
}
|
||||||
|
redraw();
|
||||||
// this may happen during AI turn when this interface is inactive
|
|
||||||
// force redraw in order to properly update interface
|
|
||||||
GH.totalRedraw();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void CMinimap::updateTile(const int3 &pos)
|
void CMinimap::updateTile(const int3 &pos)
|
||||||
|
|||||||
Reference in New Issue
Block a user