1
0
mirror of https://github.com/kepler155c/opus synced 2025-12-16 05:08:06 +00:00

alternate support

This commit is contained in:
kepler155c@gmail.com
2019-11-10 15:58:36 -07:00
parent c9fd7efc26
commit 674c6af509
6 changed files with 106 additions and 19 deletions

View File

@@ -1,8 +1,11 @@
local Alt = require('opus.alternate')
local kernel = _G.kernel
local os = _G.os
local shell = _ENV.shell
local launcherTab = kernel.getCurrent()
launcherTab.noFocus = true
kernel.hook('kernel_focus', function(_, eventData)
local focusTab = eventData and eventData[1]
@@ -17,7 +20,7 @@ kernel.hook('kernel_focus', function(_, eventData)
end
end
if nextTab == launcherTab then
shell.switchTab(shell.openTab('sys/apps/shell.lua'))
shell.switchTab(shell.openTab(Alt.get('shell')))
else
shell.switchTab(nextTab.uid)
end