|
|
@ -13,20 +13,20 @@ end
|
|
|
|
-- end
|
|
|
|
-- end
|
|
|
|
-- end)
|
|
|
|
-- end)
|
|
|
|
|
|
|
|
|
|
|
|
local safari_close_tab = hs.hotkey.new({"cmd"}, "w", function() end, function()
|
|
|
|
-- local safari_close_tab = hs.hotkey.new({"cmd"}, "w", function() end, function()
|
|
|
|
if current_app():name() == "Safari" then
|
|
|
|
-- if current_app():name() == "Safari" then
|
|
|
|
current_app():selectMenuItem({"File", "Close Tab"})
|
|
|
|
-- current_app():selectMenuItem({"File", "Close Tab"})
|
|
|
|
end
|
|
|
|
-- end
|
|
|
|
end)
|
|
|
|
-- end)
|
|
|
|
|
|
|
|
|
|
|
|
local wf = hs.window.filter
|
|
|
|
-- local wf = hs.window.filter
|
|
|
|
wf.new("Safari"):subscribe(wf.windowFocused, function()
|
|
|
|
-- wf.new("Safari"):subscribe(wf.windowFocused, function()
|
|
|
|
-- safari_esc:enable()
|
|
|
|
-- -- safari_esc:enable()
|
|
|
|
safari_close_tab:enable()
|
|
|
|
-- safari_close_tab:enable()
|
|
|
|
end):subscribe(wf.windowUnfocused, function()
|
|
|
|
-- end):subscribe(wf.windowUnfocused, function()
|
|
|
|
-- safari_esc:disable()
|
|
|
|
-- -- safari_esc:disable()
|
|
|
|
safari_close_tab:disable()
|
|
|
|
-- safari_close_tab:disable()
|
|
|
|
end)
|
|
|
|
-- end)
|
|
|
|
|
|
|
|
|
|
|
|
-- hs.hotkey.bind({"cmd", "shift"}, "[", function()
|
|
|
|
-- hs.hotkey.bind({"cmd", "shift"}, "[", function()
|
|
|
|
-- current_app():selectMenuItem({"Window", "Select Previous Tab"})
|
|
|
|
-- current_app():selectMenuItem({"Window", "Select Previous Tab"})
|
|
|
|