X-Git-Url: https://git.lizzy.rs/?a=blobdiff_plain;f=src%2FguiTable.cpp;h=e915770a412da09dec79233c745cfde581b1ad45;hb=0a0378fecef5c6b4be6d034d8bced2a1568dde81;hp=153d0010604580d392787d316b15fb520d69801b;hpb=f3abaec83be741094ef1b0949e3400fb16729f97;p=minetest.git diff --git a/src/guiTable.cpp b/src/guiTable.cpp index 153d00106..e915770a4 100644 --- a/src/guiTable.cpp +++ b/src/guiTable.cpp @@ -28,14 +28,14 @@ with this program; if not, write to the Free Software Foundation, Inc., #include #include "debug.h" #include "log.h" -#include "tile.h" +#include "client/tile.h" #include "gettime.h" #include "util/string.h" #include "util/numeric.h" #include "util/string.h" // for parseColorString() -#include "main.h" #include "settings.h" // for settings #include "porting.h" // for dpi +#include "guiscalingfilter.h" /* GUITable @@ -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