Laserlicht 4 hónapja
szülő
commit
d003030d08

+ 3 - 0
Mods/vcmi/Content/config/english.json

@@ -435,6 +435,9 @@
 	"vcmi.townWindow.upgradeAll.notAllUpgradable" : "Not enough resources to upgrade all creatures. Do you want to upgrade following creatures?",
 	"vcmi.townWindow.upgradeAll.notUpgradable" : "Not enough resources to upgrade any creature.",
 
+	"vcmi.kingdomOverview.secSkillOverflow.hover" : "More skills",
+	"vcmi.kingdomOverview.secSkillOverflow.help" : "{More skills}\n\nThis hero has more skills.\nYou can see all of them in the hero overview.",
+
 	"vcmi.logicalExpressions.anyOf"  : "Any of the following:",
 	"vcmi.logicalExpressions.allOf"  : "All of the following:",
 	"vcmi.logicalExpressions.noneOf" : "None of the following:",

+ 3 - 0
Mods/vcmi/Content/config/german.json

@@ -425,6 +425,9 @@
 	"vcmi.townWindow.upgradeAll.notAllUpgradable" : "Nicht genügend Ressourcen um alle Kreaturen aufzurüsten. Folgende Kreaturen aufrüsten?",
 	"vcmi.townWindow.upgradeAll.notUpgradable" : "Nicht genügend Ressourcen um mindestens eine Kreatur aufzurüsten.",
 
+	"vcmi.kingdomOverview.secSkillOverflow.hover" : "Mehr skills",
+	"vcmi.kingdomOverview.secSkillOverflow.help" : "{Mehr skills}\n\nDieser Held hat mehr Skills.\nIn der Heldenübersicht können alle eingesehen werden.",
+
 	"vcmi.logicalExpressions.anyOf"  : "Eines der folgenden:",
 	"vcmi.logicalExpressions.allOf"  : "Alles der folgenden:",
 	"vcmi.logicalExpressions.noneOf" : "Keines der folgenden:",

+ 6 - 1
client/windows/CExchangeWindow.cpp

@@ -401,12 +401,17 @@ void CExchangeWindow::update()
 			{
 				if(isMoreSkillsThanSlots)
 				{
-					secSkillsFull[leftRight] = std::make_shared<CMultiLineLabel>(Rect(Point(32 + 36 * m + 454 * leftRight, qeLayout ? 83 : 88), Point(34, 28)), EFonts::FONT_MEDIUM, ETextAlignment::CENTER, Colors::WHITE, "...");
+					Rect r(Point(32 + 36 * m + 454 * leftRight, qeLayout ? 83 : 88), Point(34, 28));
+					secSkillsFull[leftRight] = std::make_shared<CMultiLineLabel>(r, EFonts::FONT_MEDIUM, ETextAlignment::CENTER, Colors::WHITE, "...");
+					secSkillsFullArea[leftRight] = std::make_shared<LRClickableAreaWText>(r, LIBRARY->generaltexth->translate("vcmi.kingdomOverview.secSkillOverflow.hover"), LIBRARY->generaltexth->translate("vcmi.kingdomOverview.secSkillOverflow.help"));
 					secSkills[leftRight][m]->setSkill(SecondarySkill::NONE);
 					continue;
 				}
 				else
+				{
 					secSkillsFull[leftRight].reset();
+					secSkillsFullArea[leftRight].reset();
+				}
 			}
 
 			int id = hero->secSkills[m].first;

+ 2 - 0
client/windows/CExchangeWindow.h

@@ -14,6 +14,7 @@
 
 class CGarrisonSlot;
 class CMultiLineLabel;
+class LRClickableAreaWText;
 
 class CExchangeWindow : public CStatusbarWindow, public IGarrisonHolder, public CWindowWithArtifacts
 {
@@ -29,6 +30,7 @@ class CExchangeWindow : public CStatusbarWindow, public IGarrisonHolder, public
 	std::vector<std::shared_ptr<LRClickableAreaWTextComp>> primSkillAreas;
 	std::array<std::vector<std::shared_ptr<CSecSkillPlace>>, 2> secSkills;
 	std::array<std::shared_ptr<CMultiLineLabel>, 2> secSkillsFull;
+	std::array<std::shared_ptr<LRClickableAreaWText>, 2> secSkillsFullArea;
 
 	std::array<std::shared_ptr<CHeroArea>, 2> heroAreas;
 	std::array<std::shared_ptr<LRClickableAreaWText>, 2> specialtyAreas;

+ 3 - 1
client/windows/CKingdomInterface.cpp

@@ -988,7 +988,9 @@ CHeroItem::CHeroItem(const CGHeroInstance * Hero)
 	{
 		if(isMoreSkillsThanSlots && i == slots - 1)
 		{
-			heroInfoFull = std::make_shared<CMultiLineLabel>(Rect(Point(410+(int)i*36, 5), Point(34, 28)), EFonts::FONT_MEDIUM, ETextAlignment::CENTER, Colors::WHITE, "...");
+			Rect r(Point(410+(int)i*36, 5), Point(34, 28));
+			heroInfoFull = std::make_shared<CMultiLineLabel>(r, EFonts::FONT_MEDIUM, ETextAlignment::CENTER, Colors::WHITE, "...");
+			heroInfoFullArea = std::make_shared<LRClickableAreaWText>(r, LIBRARY->generaltexth->translate("vcmi.kingdomOverview.secSkillOverflow.hover"), LIBRARY->generaltexth->translate("vcmi.kingdomOverview.secSkillOverflow.help"));
 			continue;
 		}
 		auto data = std::make_shared<InfoBoxHeroData>(IInfoBoxData::HERO_SECONDARY_SKILL, hero, (int)i);

+ 2 - 0
client/windows/CKingdomInterface.h

@@ -32,6 +32,7 @@ class CTabbedInt;
 class CGStatusBar;
 class CGarrisonInt;
 class CMultiLineLabel;
+class LRClickableAreaWText;
 
 class CKingdHeroList;
 class CKingdTownList;
@@ -311,6 +312,7 @@ class CHeroItem : public CIntObject, public IGarrisonHolder
 	std::shared_ptr<CToggleGroup> artButtons;
 	std::vector<std::shared_ptr<InfoBox>> heroInfo;
 	std::shared_ptr<CMultiLineLabel> heroInfoFull;
+	std::shared_ptr<LRClickableAreaWText> heroInfoFullArea;
 	std::shared_ptr<MoraleLuckBox> morale;
 	std::shared_ptr<MoraleLuckBox> luck;