fix origin widget for PressEnd events generated by keyboard shortcuts

This commit is contained in:
airstruck
2016-01-19 12:53:11 -05:00
parent ab43dabcb9
commit 78e02c190e
2 changed files with 9 additions and 12 deletions

View File

@@ -170,7 +170,7 @@ end
function Input:handlePressEnd (layout, button, x, y, widget, shortcut)
local hit, widget = checkHit(widget or layout:getWidgetAt(x, y), layout)
local originWidget = self.pressedWidgets[button]
local originWidget = widget or self.pressedWidgets[button]
if not originWidget then return end
if hit then
originWidget.pressed[button] = nil