From c159ae7828ac20935b129e67a576bcce60d5e0c9 Mon Sep 17 00:00:00 2001 From: Kenny Shields Date: Sat, 23 Aug 2014 15:58:44 -0400 Subject: [PATCH] Fix columnlistarea scroll wheel detection --- objects/internal/columnlist/columnlistarea.lua | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/objects/internal/columnlist/columnlistarea.lua b/objects/internal/columnlist/columnlistarea.lua index cfcb7bc..32b5003 100644 --- a/objects/internal/columnlist/columnlistarea.lua +++ b/objects/internal/columnlist/columnlistarea.lua @@ -164,8 +164,16 @@ function newobject:mousepressed(x, y, button) end end - if self.bar and self:IsTopList() then - local bar = self:GetScrollBar() + local bar = false + if self.vbar and self.hbar then + bar = self:GetVerticalScrollBody():GetScrollBar() + elseif self.vbar and not self.hbar then + bar = self:GetVerticalScrollBody():GetScrollBar() + elseif not self.var and self.hbar then + bar = self:GetHorizontalScrollBody():GetScrollBar() + end + + if self:IsTopList() and bar then if self.dtscrolling then local dt = love.timer.getDelta() if button == "wu" then