mirror of
https://github.com/vcmi/vcmi.git
synced 2024-11-28 08:48:48 +02:00
bigger line for folder
This commit is contained in:
parent
f24c636d17
commit
48747eea9d
Before Width: | Height: | Size: 1.2 KiB After Width: | Height: | Size: 1.2 KiB |
BIN
Mods/vcmi/Data/lobby/selectionEmptyLine.png
Normal file
BIN
Mods/vcmi/Data/lobby/selectionEmptyLine.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 4.5 KiB |
@ -2,7 +2,6 @@
|
||||
"basepath" : "mapFormatIcons/",
|
||||
"images" :
|
||||
[
|
||||
{ "frame" : 3, "file" : "vcmi1.png"},
|
||||
{ "frame" : 99, "file" : "folder.png"}
|
||||
{ "frame" : 3, "file" : "vcmi1.png"}
|
||||
]
|
||||
}
|
@ -788,6 +788,7 @@ SelectionTab::ListItem::ListItem(Point position, std::shared_ptr<CAnimation> ico
|
||||
: CIntObject(LCLICK, position)
|
||||
{
|
||||
OBJ_CONSTRUCTION_CAPTURING_ALL_NO_DISPOSE;
|
||||
pictureEmptyLine = std::make_shared<CPicture>("lobby/selectionEmptyLine.png", -8, -14);
|
||||
labelName = std::make_shared<CLabel>(184, 0, FONT_SMALL, ETextAlignment::CENTER, Colors::WHITE);
|
||||
labelName->setAutoRedraw(false);
|
||||
labelAmountOfPlayers = std::make_shared<CLabel>(8, 0, FONT_SMALL, ETextAlignment::CENTER, Colors::WHITE);
|
||||
@ -797,6 +798,7 @@ SelectionTab::ListItem::ListItem(Point position, std::shared_ptr<CAnimation> ico
|
||||
labelMapSizeLetter = std::make_shared<CLabel>(41, 0, FONT_SMALL, ETextAlignment::CENTER, Colors::WHITE);
|
||||
labelMapSizeLetter->setAutoRedraw(false);
|
||||
// FIXME: This -12 should not be needed, but for some reason CAnimImage displaced otherwise
|
||||
iconFolder = std::make_shared<CPicture>("lobby/iconFolder.png", -8, -12);
|
||||
iconFormat = std::make_shared<CAnimImage>(iconsFormats, 0, 0, 59, -12);
|
||||
iconVictoryCondition = std::make_shared<CAnimImage>(iconsVictory, 0, 0, 277, -12);
|
||||
iconLossCondition = std::make_shared<CAnimImage>(iconsLoss, 0, 0, 310, -12);
|
||||
@ -808,6 +810,8 @@ void SelectionTab::ListItem::updateItem(std::shared_ptr<ElementInfo> info, bool
|
||||
{
|
||||
labelAmountOfPlayers->disable();
|
||||
labelMapSizeLetter->disable();
|
||||
iconFolder->disable();
|
||||
pictureEmptyLine->disable();
|
||||
iconFormat->disable();
|
||||
iconVictoryCondition->disable();
|
||||
iconLossCondition->disable();
|
||||
@ -821,8 +825,9 @@ void SelectionTab::ListItem::updateItem(std::shared_ptr<ElementInfo> info, bool
|
||||
{
|
||||
labelAmountOfPlayers->disable();
|
||||
labelMapSizeLetter->disable();
|
||||
iconFormat->enable();
|
||||
iconFormat->setFrame(99);
|
||||
iconFolder->enable();
|
||||
pictureEmptyLine->enable();
|
||||
iconFormat->disable();
|
||||
iconVictoryCondition->disable();
|
||||
iconLossCondition->disable();
|
||||
labelNumberOfCampaignMaps->disable();
|
||||
@ -836,6 +841,8 @@ void SelectionTab::ListItem::updateItem(std::shared_ptr<ElementInfo> info, bool
|
||||
{
|
||||
labelAmountOfPlayers->disable();
|
||||
labelMapSizeLetter->disable();
|
||||
iconFolder->disable();
|
||||
pictureEmptyLine->disable();
|
||||
iconFormat->disable();
|
||||
iconVictoryCondition->disable();
|
||||
iconLossCondition->disable();
|
||||
@ -856,6 +863,8 @@ void SelectionTab::ListItem::updateItem(std::shared_ptr<ElementInfo> info, bool
|
||||
labelMapSizeLetter->enable();
|
||||
labelMapSizeLetter->setText(info->getMapSizeName());
|
||||
labelMapSizeLetter->setColor(color);
|
||||
iconFolder->disable();
|
||||
pictureEmptyLine->disable();
|
||||
iconFormat->enable();
|
||||
iconFormat->setFrame(info->getMapSizeFormatIconId());
|
||||
iconVictoryCondition->enable();
|
||||
|
@ -45,9 +45,11 @@ class SelectionTab : public CIntObject
|
||||
std::shared_ptr<CLabel> labelAmountOfPlayers;
|
||||
std::shared_ptr<CLabel> labelNumberOfCampaignMaps;
|
||||
std::shared_ptr<CLabel> labelMapSizeLetter;
|
||||
std::shared_ptr<CPicture> iconFolder;
|
||||
std::shared_ptr<CAnimImage> iconFormat;
|
||||
std::shared_ptr<CAnimImage> iconVictoryCondition;
|
||||
std::shared_ptr<CAnimImage> iconLossCondition;
|
||||
std::shared_ptr<CPicture> pictureEmptyLine;
|
||||
std::shared_ptr<CLabel> labelName;
|
||||
|
||||
ListItem(Point position, std::shared_ptr<CAnimation> iconsFormats, std::shared_ptr<CAnimation> iconsVictory, std::shared_ptr<CAnimation> iconsLoss);
|
||||
|
Loading…
Reference in New Issue
Block a user