diff options
author | Andrei Karas <akaras@inbox.ru> | 2013-12-15 00:23:39 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2013-12-15 00:23:39 +0300 |
commit | 53d28e67f8b7966596818af7cbfd360df241b332 (patch) | |
tree | 2924b2c260c14bfb8344d75c4bf7482d5263a39a /src/gui/widgets | |
parent | 36de2c64d6bba077775360c9c0d681f0a096ffc3 (diff) | |
download | manaverse-53d28e67f8b7966596818af7cbfd360df241b332.tar.gz manaverse-53d28e67f8b7966596818af7cbfd360df241b332.tar.bz2 manaverse-53d28e67f8b7966596818af7cbfd360df241b332.tar.xz manaverse-53d28e67f8b7966596818af7cbfd360df241b332.zip |
rename calcTile methods into separate names calcTileVertexes, calTileCollection.
Diffstat (limited to 'src/gui/widgets')
-rw-r--r-- | src/gui/widgets/avatarlistbox.cpp | 2 | ||||
-rw-r--r-- | src/gui/widgets/button.cpp | 5 | ||||
-rw-r--r-- | src/gui/widgets/emotepage.cpp | 2 | ||||
-rw-r--r-- | src/gui/widgets/scrollarea.cpp | 2 | ||||
-rw-r--r-- | src/gui/widgets/shortcutcontainer.cpp | 2 | ||||
-rw-r--r-- | src/gui/widgets/slider.cpp | 17 | ||||
-rw-r--r-- | src/gui/widgets/tabs/tab.cpp | 3 | ||||
-rw-r--r-- | src/gui/widgets/window.cpp | 12 |
8 files changed, 29 insertions, 16 deletions
diff --git a/src/gui/widgets/avatarlistbox.cpp b/src/gui/widgets/avatarlistbox.cpp index 6726475d2..0d222595d 100644 --- a/src/gui/widgets/avatarlistbox.cpp +++ b/src/gui/widgets/avatarlistbox.cpp @@ -132,7 +132,7 @@ void AvatarListBox::draw(gcn::Graphics *gcnGraphics) { if (useCaching) { - graphics->calcTile(&vertexes, icon, + graphics->calcTileCollection(&vertexes, icon, mImagePadding, y + mPadding); } else diff --git a/src/gui/widgets/button.cpp b/src/gui/widgets/button.cpp index 91c531f6b..f0534c129 100644 --- a/src/gui/widgets/button.cpp +++ b/src/gui/widgets/button.cpp @@ -485,12 +485,13 @@ void Button::draw(gcn::Graphics *graphics) { if (isPressed()) { - g2->calcTile(mVertexes2, mImages[mode], + g2->calcTileCollection(mVertexes2, mImages[mode], imageX + 1, imageY + 1); } else { - g2->calcTile(mVertexes2, mImages[mode], imageX, imageY); + g2->calcTileCollection(mVertexes2, + mImages[mode], imageX, imageY); } } } diff --git a/src/gui/widgets/emotepage.cpp b/src/gui/widgets/emotepage.cpp index a68836a96..472e6c1f4 100644 --- a/src/gui/widgets/emotepage.cpp +++ b/src/gui/widgets/emotepage.cpp @@ -84,7 +84,7 @@ void EmotePage::draw(gcn::Graphics *graphics) const Image *const image = *it; if (image) { - g->calcTile(mVertexes, image, x, y); + g->calcTileCollection(mVertexes, image, x, y); x += emoteWidth; if (x + emoteWidth > width) { diff --git a/src/gui/widgets/scrollarea.cpp b/src/gui/widgets/scrollarea.cpp index a2e1ca4aa..b786ccbb7 100644 --- a/src/gui/widgets/scrollarea.cpp +++ b/src/gui/widgets/scrollarea.cpp @@ -466,7 +466,7 @@ void ScrollArea::calcButton(gcn::Graphics *const graphics, if (buttons[dir][state]) { - static_cast<Graphics*>(graphics)->calcTile( + static_cast<Graphics*>(graphics)->calcTileCollection( mVertexes, buttons[dir][state], dim.x, dim.y); } } diff --git a/src/gui/widgets/shortcutcontainer.cpp b/src/gui/widgets/shortcutcontainer.cpp index a68bc8b07..7cd8a2f38 100644 --- a/src/gui/widgets/shortcutcontainer.cpp +++ b/src/gui/widgets/shortcutcontainer.cpp @@ -98,7 +98,7 @@ void ShortcutContainer::drawBackground(Graphics *g) mVertexes->clear(); for (unsigned i = 0; i < mMaxItems; i ++) { - g->calcTile(mVertexes, mBackgroundImg, + g->calcTileCollection(mVertexes, mBackgroundImg, (i % mGridWidth) * mBoxWidth, (i / mGridWidth) * mBoxHeight); } diff --git a/src/gui/widgets/slider.cpp b/src/gui/widgets/slider.cpp index 47d4e2215..313a08162 100644 --- a/src/gui/widgets/slider.cpp +++ b/src/gui/widgets/slider.cpp @@ -146,7 +146,8 @@ void Slider::draw(gcn::Graphics *graphics) mVertexes->clear(); if (!mHasMouse) { - g->calcTile(mVertexes, buttons[0].grid[HSTART], x, y); + g->calcTileCollection(mVertexes, + buttons[0].grid[HSTART], x, y); const int width = buttons[0].grid[HSTART]->getWidth(); w -= width + buttons[0].grid[HEND]->getWidth(); @@ -160,18 +161,19 @@ void Slider::draw(gcn::Graphics *graphics) } x += w; - g->calcTile(mVertexes, buttons[0].grid[HEND], x, y); + g->calcTileCollection(mVertexes, buttons[0].grid[HEND], x, y); const Image *const img = buttons[0].grid[HGRIP]; if (img) { - g->calcTile(mVertexes, img, getMarkerPosition(), + g->calcTileCollection(mVertexes, img, getMarkerPosition(), (mDimension.height - img->getHeight()) / 2); } } else { - g->calcTile(mVertexes, buttons[1].grid[HSTART], x, y); + g->calcTileCollection(mVertexes, + buttons[1].grid[HSTART], x, y); const int width = buttons[1].grid[HSTART]->getWidth(); w -= width; @@ -188,12 +190,15 @@ void Slider::draw(gcn::Graphics *graphics) x += w; if (buttons[1].grid[HEND]) - g->calcTile(mVertexes, buttons[1].grid[HEND], x, y); + { + g->calcTileCollection(mVertexes, + buttons[1].grid[HEND], x, y); + } const Image *const img = buttons[1].grid[HGRIP]; if (img) { - g->calcTile(mVertexes, img, getMarkerPosition(), + g->calcTileCollection(mVertexes, img, getMarkerPosition(), (mDimension.height - img->getHeight()) / 2); } } diff --git a/src/gui/widgets/tabs/tab.cpp b/src/gui/widgets/tabs/tab.cpp index fd5d8ffc5..f1e45fa42 100644 --- a/src/gui/widgets/tabs/tab.cpp +++ b/src/gui/widgets/tabs/tab.cpp @@ -224,7 +224,8 @@ void Tab::draw(gcn::Graphics *graphics) if (skin1) { const int padding = skin1->getPadding(); - g->calcTile(mVertexes, mImage, padding, padding); + g->calcTileCollection(mVertexes, mImage, + padding, padding); } } } diff --git a/src/gui/widgets/window.cpp b/src/gui/widgets/window.cpp index a95bc0877..ad8e9e7eb 100644 --- a/src/gui/widgets/window.cpp +++ b/src/gui/widgets/window.cpp @@ -239,7 +239,10 @@ void Window::draw(gcn::Graphics *graphics) const Image *const button = mSkin->getCloseImage( mResizeHandles == CLOSE); if (button) - g->calcTile(mVertexes, button, mCloseRect.x, mCloseRect.y); + { + g->calcTileCollection(mVertexes, button, + mCloseRect.x, mCloseRect.y); + } } // Draw Sticky Button if (mStickyButton) @@ -247,13 +250,16 @@ void Window::draw(gcn::Graphics *graphics) const Image *const button = mSkin->getStickyImage(mSticky); if (button) { - g->calcTile(mVertexes, button, + g->calcTileCollection(mVertexes, button, mStickyRect.x, mStickyRect.y); } } if (mGrip) - g->calcTile(mVertexes, mGrip, mGripRect.x, mGripRect.y); + { + g->calcTileCollection(mVertexes, mGrip, + mGripRect.x, mGripRect.y); + } } else { |