about summary refs log tree commit diff stats
path: root/keychord.lua
diff options
context:
space:
mode:
authorKartik K. Agaram <vc@akkartik.com>2022-05-26 20:40:50 -0700
committerKartik K. Agaram <vc@akkartik.com>2022-05-26 20:40:50 -0700
commit0fab1b499df3eb887786526b4c38827c2027a1e8 (patch)
tree728a9e26b48910c66d9be7f170dff41ad5e78392 /keychord.lua
parentdd635546e3b43f7e50de88ccdc8464558f0a028a (diff)
downloadlines.love-0fab1b499df3eb887786526b4c38827c2027a1e8.tar.gz
paste in text with M-v
Diffstat (limited to 'keychord.lua')
-rw-r--r--keychord.lua5
1 files changed, 5 insertions, 0 deletions
diff --git a/keychord.lua b/keychord.lua
index 12feef7..07e34cb 100644
--- a/keychord.lua
+++ b/keychord.lua
@@ -23,3 +23,8 @@ function App.combine_modifiers(key)
   result = result..key
   return result
 end
+
+function App.modifier_down()
+  local down = love.keyboard.isDown
+  return down('lctrl') or down('rctrl') or down('lalt') or down('ralt') or down('lgui') or down('rgui')
+end