mirror of
https://github.com/LukeSmithxyz/voidrice.git
synced 2026-03-20 01:37:45 +01:00
23 lines
433 B
Lua
23 lines
433 B
Lua
-- Adds an additional keybinding to pause an unpaused mpv
|
|
|
|
local mp = require 'mp'
|
|
local utils = require 'mp.utils'
|
|
local msg = require 'mp.msg'
|
|
|
|
local opts = {
|
|
|
|
pause_toggle = "\\"
|
|
|
|
}
|
|
|
|
(require 'mp.options').read_options(opts, "pause_toggle")
|
|
-- main
|
|
-- keybind to toggle pause
|
|
|
|
mp.add_key_binding(opts.pause_toggle, "pause_toggle", function()
|
|
if (mp.get_property('pause') == "no") then
|
|
mp.commandv('cycle', 'pause')
|
|
end
|
|
end)
|
|
|