summaryrefslogtreecommitdiff
path: root/src/gui/outfitwindow.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2013-06-07 21:47:00 +0300
committerAndrei Karas <akaras@inbox.ru>2013-06-07 21:47:00 +0300
commit4f8e8c36290e46c00fa0266c4e4af553fac59a4c (patch)
tree618c1c9359a44aae173d5f7276e4bbfafccd7111 /src/gui/outfitwindow.cpp
parentb638b4ca0dbe20e83e30a18f30357ddcc85c64d8 (diff)
downloadmanaverse-4f8e8c36290e46c00fa0266c4e4af553fac59a4c.tar.gz
manaverse-4f8e8c36290e46c00fa0266c4e4af553fac59a4c.tar.bz2
manaverse-4f8e8c36290e46c00fa0266c4e4af553fac59a4c.tar.xz
manaverse-4f8e8c36290e46c00fa0266c4e4af553fac59a4c.zip
Fix code style.
Diffstat (limited to 'src/gui/outfitwindow.cpp')
-rw-r--r--src/gui/outfitwindow.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/gui/outfitwindow.cpp b/src/gui/outfitwindow.cpp
index 45ee8465f..ca3f504ad 100644
--- a/src/gui/outfitwindow.cpp
+++ b/src/gui/outfitwindow.cpp
@@ -487,12 +487,12 @@ void OutfitWindow::mouseReleased(gcn::MouseEvent &event)
int OutfitWindow::getIndexFromGrid(const int pointX, const int pointY) const
{
- const gcn::Rectangle tRect = gcn::Rectangle(
- mPadding, mTitleBarHeight, mGridWidth * mBoxWidth, mGridHeight * mBoxHeight);
+ const gcn::Rectangle tRect = gcn::Rectangle(mPadding, mTitleBarHeight,
+ mGridWidth * mBoxWidth, mGridHeight * mBoxHeight);
if (!tRect.isPointInRect(pointX, pointY))
return -1;
- const int index = (((pointY - mTitleBarHeight) / mBoxHeight) * mGridWidth) +
- (pointX - mPadding) / mBoxWidth;
+ const int index = (((pointY - mTitleBarHeight) / mBoxHeight) * mGridWidth)
+ + (pointX - mPadding) / mBoxWidth;
if (index >= static_cast<int>(OUTFIT_ITEM_COUNT) || index < 0)
return -1;
return index;