From afdb22dcfeb898e051ed360fce04152b861aa3ad Mon Sep 17 00:00:00 2001 From: ruki Date: Thu, 18 Jan 2018 22:35:15 +0800 Subject: improve bounds for view --- xmake/core/ui/program.lua | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'xmake/core/ui/program.lua') diff --git a/xmake/core/ui/program.lua b/xmake/core/ui/program.lua index 82ada0bcf..ff152584f 100644 --- a/xmake/core/ui/program.lua +++ b/xmake/core/ui/program.lua @@ -156,10 +156,11 @@ function program:event_on(e) -- do event for focused views while focused_view and focused_view ~= self do + local parent = focused_view:parent() if focused_view:event_on(e) then return true end - focused_view = focused_view:parent() + focused_view = parent end -- quit program? -- cgit v1.3.1