summaryrefslogtreecommitdiff
path: root/src/guiTable.cpp
diff options
context:
space:
mode:
authorKahrl <kahrl@gmx.net>2015-01-10 19:56:14 +0100
committerKahrl <kahrl@gmx.net>2015-01-10 19:56:14 +0100
commitb7c0e4b3336ef5bdb0bdd6baa3257787886b2c73 (patch)
tree1837739c47f77808eb3c4cfe0eb914fc22b73309 /src/guiTable.cpp
parent3b16103ca69dc0182f5adbd63c32ef14d886e3f8 (diff)
downloadminetest-b7c0e4b3336ef5bdb0bdd6baa3257787886b2c73.tar.gz
minetest-b7c0e4b3336ef5bdb0bdd6baa3257787886b2c73.tar.bz2
minetest-b7c0e4b3336ef5bdb0bdd6baa3257787886b2c73.zip
Fix clipping rectangle of GUITable row highlight
Diffstat (limited to 'src/guiTable.cpp')
-rw-r--r--src/guiTable.cpp9
1 files changed, 5 insertions, 4 deletions
diff --git a/src/guiTable.cpp b/src/guiTable.cpp
index 153d00106..05db228da 100644
--- a/src/guiTable.cpp
+++ b/src/guiTable.cpp
@@ -638,10 +638,11 @@ void GUITable::draw()
client_clip.UpperLeftCorner.Y += 1;
client_clip.UpperLeftCorner.X += 1;
client_clip.LowerRightCorner.Y -= 1;
- client_clip.LowerRightCorner.X -=
- m_scrollbar->isVisible() ?
- skin->getSize(gui::EGDS_SCROLLBAR_SIZE) :
- 1;
+ client_clip.LowerRightCorner.X -= 1;
+ if (m_scrollbar->isVisible()) {
+ client_clip.LowerRightCorner.X =
+ m_scrollbar->getAbsolutePosition().UpperLeftCorner.X;
+ }
client_clip.clipAgainst(AbsoluteClippingRect);
// draw visible rows