Fix ghost item border when dropping non-item objects (#1164)

This commit is contained in:
diath
2021-09-29 21:03:01 +02:00
committed by GitHub
parent 1d614e294c
commit 9eb13494f9

View File

@@ -20,6 +20,7 @@ function UIItem:onDragLeave(droppedWidget, mousePos)
end
function UIItem:onDrop(widget, mousePos)
self:setBorderWidth(0)
if not self:canAcceptDrop(widget, mousePos) then
return false
@@ -47,7 +48,6 @@ function UIItem:onDrop(widget, mousePos)
g_game.move(item, toPos, 1)
end
self:setBorderWidth(0)
return true
end