From 2396d6d5ccf331ccbd5d0e497b40a69cbf24c173 Mon Sep 17 00:00:00 2001 From: Philipp Hochkamp Date: Fri, 13 Jan 2023 13:15:23 +0100 Subject: [PATCH] fixi fixi --- hosts/daedalus/finicky.js | 4 ++++ hosts/daedalus/hammerspoon.lua | 35 +++------------------------------- 2 files changed, 7 insertions(+), 32 deletions(-) diff --git a/hosts/daedalus/finicky.js b/hosts/daedalus/finicky.js index 9be3f777..dfa47e21 100644 --- a/hosts/daedalus/finicky.js +++ b/hosts/daedalus/finicky.js @@ -8,6 +8,10 @@ module.exports = { { match: /^https?:\/\/.*\.atlassian\.com\/.*$/, browser: "Vivaldi.app" + }, + { + match: 'localhost:44422', + browser: "Vivaldi.app" } ] } diff --git a/hosts/daedalus/hammerspoon.lua b/hosts/daedalus/hammerspoon.lua index 7289c319..17988aba 100644 --- a/hosts/daedalus/hammerspoon.lua +++ b/hosts/daedalus/hammerspoon.lua @@ -295,36 +295,7 @@ end) -- Mouse Shortcuts ---------------------------------------------------------------------------------------------------- -local function handleMouse2() - local application = hs.application.frontmostApplication() - - -- Safari: Close tab - if application:bundleID() == bundleID.safari then - hs.eventtap.keyStroke({ modifier.cmd }, "w") - - -- Safari Technology Preview: Close tab - elseif application:bundleID() == bundleID.safariTechnologyPreview then - hs.eventtap.keyStroke({ modifier.cmd }, "w") - - -- Google Chrome: Close tab - elseif application:bundleID() == bundleID.googleChrome then - hs.eventtap.keyStroke({ modifier.cmd }, "w") - - -- Firefox: Close tab - elseif application:bundleID() == bundleID.firefox then - hs.eventtap.keyStroke({ modifier.cmd }, "w") - - -- Teams: End call - elseif application:bundleID() == bundleID.teams then - hs.eventtap.keyStroke({ modifier.cmd, modifier.shift }, "h") - - -- Spotify: Toggle play - elseif application:bundleID() == bundleID.spotify then - hs.eventtap.keyStroke({}, "space") - end -end - -local function handleMouse3() +local function handleMouse5() hs.eventtap.keyStroke({ modifier.cmd }, "left") end @@ -334,8 +305,8 @@ end -- bind mouse3/4 to back and forward mouseTap = hs.eventtap.new({ hs.eventtap.event.types.otherMouseDown }, function(event) - if event:getButtonState(3) then - handleMouse3() + if event:getButtonState(5) then + handleMouse5() elseif event:getButtonState(4) then handleMouse4() end