diff options
author | Andrei Karas <akaras@inbox.ru> | 2020-02-23 09:30:51 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2020-02-23 09:30:51 +0300 |
commit | 1e2a88e975019929c4c7e3154537865cc09550a6 (patch) | |
tree | ae8bc68ad3a3f6b61a5e2d511d7fc17daa22bd0e /src/gui/popups | |
parent | 6941fd4eeb1dce20aba8c42fd030c2690c37b731 (diff) | |
download | plus-1e2a88e975019929c4c7e3154537865cc09550a6.tar.gz plus-1e2a88e975019929c4c7e3154537865cc09550a6.tar.bz2 plus-1e2a88e975019929c4c7e3154537865cc09550a6.tar.xz plus-1e2a88e975019929c4c7e3154537865cc09550a6.zip |
Fix some code style issues
Diffstat (limited to 'src/gui/popups')
-rw-r--r-- | src/gui/popups/itempopup.cpp | 2 | ||||
-rw-r--r-- | src/gui/popups/popupmenu.cpp | 2 | ||||
-rw-r--r-- | src/gui/popups/skillpopup.cpp | 2 |
3 files changed, 3 insertions, 3 deletions
diff --git a/src/gui/popups/itempopup.cpp b/src/gui/popups/itempopup.cpp index 0e9dd031f..3cb80b7ac 100644 --- a/src/gui/popups/itempopup.cpp +++ b/src/gui/popups/itempopup.cpp @@ -294,7 +294,6 @@ void ItemPopup::setItem(const ItemInfo &item, minWidth = mItemOptions->getMinWidth(); const int numRowsDesc = mItemDesc->getNumberOfRows(); - const int numRowsEffect = mItemEffect->getNumberOfRows(); const int numRowsWeight = mItemWeight->getNumberOfRows(); const int numRowsCards = mItemCards->getNumberOfRows(); const int numRowsOptions = mItemOptions->getNumberOfRows(); @@ -312,6 +311,7 @@ void ItemPopup::setItem(const ItemInfo &item, } else { + const int numRowsEffect = mItemEffect->getNumberOfRows(); setContentSize(minWidth, (numRowsDesc + numRowsEffect + 2 + numRowsWeight + numRowsCards + numRowsOptions) * height); mItemEffect->setPosition(0, (numRowsDesc + 2) * height); diff --git a/src/gui/popups/popupmenu.cpp b/src/gui/popups/popupmenu.cpp index dcba43e1f..6ecbd6a9f 100644 --- a/src/gui/popups/popupmenu.cpp +++ b/src/gui/popups/popupmenu.cpp @@ -1393,10 +1393,10 @@ void PopupMenu::handleLink(const std::string &link, { if (localPlayer != nullptr) { - const int num = atoi(link.substr(10).c_str()); const Guild *const guild = localPlayer->getGuild(); if (guild != nullptr) { + const int num = atoi(link.substr(10).c_str()); guildHandler->changeMemberPostion( guild->getMember(mName), num); } diff --git a/src/gui/popups/skillpopup.cpp b/src/gui/popups/skillpopup.cpp index f7d86d85c..8d5950b11 100644 --- a/src/gui/popups/skillpopup.cpp +++ b/src/gui/popups/skillpopup.cpp @@ -209,7 +209,6 @@ void SkillPopup::show(const SkillInfo *const skill, minWidth = mSkillCastType->getMinWidth(); const int numRowsDesc = mSkillDesc->getNumberOfRows(); - const int numRowsEffect = mSkillEffect->getNumberOfRows(); const int numRowsLevel = mSkillLevel->getNumberOfRows(); const int numRowsCast = mSkillCastType->getNumberOfRows(); const int height = getFont()->getHeight(); @@ -223,6 +222,7 @@ void SkillPopup::show(const SkillInfo *const skill, } else { + const int numRowsEffect = mSkillEffect->getNumberOfRows(); setContentSize(minWidth, (numRowsDesc + numRowsLevel + numRowsEffect + numRowsCast + 1) * height); |