summaryrefslogtreecommitdiff
path: root/src/gui/windows
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2018-10-19 06:55:28 +0300
committerAndrei Karas <akaras@inbox.ru>2018-10-19 06:55:28 +0300
commit98c74738f21d7ae256f1273b6c1614ee64e2a3ad (patch)
tree95a1af0071c774021c781611d215fee84358a807 /src/gui/windows
parenta0b050fd82177f38b8bbf3360159d57886e2a347 (diff)
downloadmanaplus-98c74738f21d7ae256f1273b6c1614ee64e2a3ad.tar.gz
manaplus-98c74738f21d7ae256f1273b6c1614ee64e2a3ad.tar.bz2
manaplus-98c74738f21d7ae256f1273b6c1614ee64e2a3ad.tar.xz
manaplus-98c74738f21d7ae256f1273b6c1614ee64e2a3ad.zip
Fix code style.
Diffstat (limited to 'src/gui/windows')
-rw-r--r--src/gui/windows/charcreatedialog.cpp6
-rw-r--r--src/gui/windows/ministatuswindow.cpp6
2 files changed, 6 insertions, 6 deletions
diff --git a/src/gui/windows/charcreatedialog.cpp b/src/gui/windows/charcreatedialog.cpp
index be5756102..49dcd8314 100644
--- a/src/gui/windows/charcreatedialog.cpp
+++ b/src/gui/windows/charcreatedialog.cpp
@@ -649,11 +649,11 @@ void CharCreateDialog::unlock()
int CharCreateDialog::getDistributedPoints() const
{
- int points = 0;
+ unsigned int points = 0;
for (size_t i = 0, sz = mAttributeSlider.size(); i < sz; i++)
- points += CAST_S32(mAttributeSlider[i]->getValue());
- return points;
+ points += CAST_U32(mAttributeSlider[i]->getValue());
+ return CAST_S32(points);
}
void CharCreateDialog::setAttributes(const StringVect &labels,
diff --git a/src/gui/windows/ministatuswindow.cpp b/src/gui/windows/ministatuswindow.cpp
index e98e607be..69dbcbf45 100644
--- a/src/gui/windows/ministatuswindow.cpp
+++ b/src/gui/windows/ministatuswindow.cpp
@@ -253,14 +253,14 @@ void MiniStatusWindow::eraseIcon(const int index)
void MiniStatusWindow::drawIcons(Graphics *const graphics)
{
// Draw icons
- int icon_x = mMaxX + mIconPadding;
+ unsigned int icon_x = mMaxX + mIconPadding;
for (size_t i = 0, sz = mIcons.size(); i < sz; i ++)
{
const AnimatedSprite *const icon = mIcons[i];
if (icon != nullptr)
{
- icon->draw(graphics, icon_x, mIconPadding);
- icon_x += mIconSpacing + icon->getWidth();
+ icon->draw(graphics, CAST_S32(icon_x), mIconPadding);
+ icon_x += CAST_U32(mIconSpacing + icon->getWidth());
}
}
}