summaryrefslogtreecommitdiff
path: root/xmake/core/ui/program.lua
diff options
context:
space:
mode:
Diffstat (limited to 'xmake/core/ui/program.lua')
-rw-r--r--xmake/core/ui/program.lua3
1 files changed, 2 insertions, 1 deletions
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?