Skip to content

Commit

Permalink
fix: only trigger mouse drag if screenrow==1
Browse files Browse the repository at this point in the history
fixes #193
  • Loading branch information
willothy committed Mar 20, 2024
1 parent 7310f19 commit 321bcde
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions lua/cokeline/hover.lua
Original file line number Diff line number Diff line change
Expand Up @@ -221,6 +221,10 @@ local function on_drag(pos)
end
M.clear_hovered()
end
if pos.screenrow ~= 1 then
M.clear_dragging()
return
end
if pos.dragging == "l" then
local current, bufs = M.get_current(pos.screencol)
if current == nil or bufs == nil or current.kind ~= "buffer" then
Expand Down

0 comments on commit 321bcde

Please sign in to comment.