1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-11-29 23:07:48 +02:00

virtual CWindowObject

This commit is contained in:
SoundSSGood
2024-04-23 16:21:45 +03:00
parent 25d2b468c3
commit 20471c9c2f
17 changed files with 74 additions and 145 deletions

View File

@@ -19,7 +19,6 @@
#include "../CPlayerInterface.h"
#include "../gui/CGuiHandler.h"
#include "../gui/CursorHandler.h"
#include "../gui/TextAlignment.h"
#include "../gui/Shortcut.h"
#include "../gui/WindowHandler.h"
@@ -71,7 +70,7 @@ CHeroSwitcher::CHeroSwitcher(CHeroWindow * owner_, Point pos_, const CGHeroInsta
}
CHeroWindow::CHeroWindow(const CGHeroInstance * hero)
: CStatusbarWindow(PLAYER_COLORED, ImagePath::builtin("HeroScr4"))
: CWindowObject(PLAYER_COLORED, ImagePath::builtin("HeroScr4"))
{
auto & heroscrn = CGI->generaltexth->heroscrn;
@@ -360,9 +359,3 @@ bool CHeroWindow::holdsGarrison(const CArmedInstance * army)
{
return army == curHero;
}
void CHeroWindow::deactivate()
{
CCS->curh->dragAndDropCursor(nullptr);
CIntObject::deactivate();
}