diff options
| -rw-r--r-- | init.org | 15 | 
1 files changed, 9 insertions, 6 deletions
| @@ -2937,22 +2937,24 @@        (defvar jao-mopidy-port 6669)        (jao-mpc-setup jao-mopidy-port) +      (defun jao-mpc-pport () +        (when (jao-mpc--playing-p jao-mopidy-port) jao-mopidy-port)) +        (defmacro jao-defun-play (name &optional mpc-name)          `(defun ,(intern (format "jao-player-%s" name)) ()             (interactive) -           (,(intern (format "jao-mpc-%s" (or mpc-name name))) -            (when (jao-mpc--playing-p jao-mopidy-port) -              jao-mopidy-port)))) +           (,(intern (format "jao-mpc-%s" (or mpc-name name))) (jao-mpc-pport))))        (jao-defun-play toggle)        (jao-defun-play next)        (jao-defun-play previous)        (jao-defun-play stop) -      (jao-defun-play seek)        (jao-defun-play echo echo-current)        (jao-defun-play list show-playlist)        (jao-defun-play info lyrics-track-data) +      (defun jao-player-seek (delta) (jao-mpc-seek delta (jao-mpc-pport))) +        (defalias 'jao-player-browse 'jao-mpc-show-albums)        (defalias 'jao-player-connect 'jao-mpc-connect)        (defalias 'jao-player-play 'jao-mpc-play) @@ -3005,10 +3007,11 @@          (global-map "s-m" :color blue :quit-key "q")          ("Play"           (("m" jao-player-toggle "toggle") -          ("s" (espotify-play-pause) "spotify")            ("n" jao-player-next "next")            ("p" jao-player-previous "previous") -          ("f" (jao-player-seek 10) "seek fwd" :color red) +          ("s" (espotify-play-pause) "toggle spotify")) +         "Seek" +         (("f" (jao-player-seek 10) "seek fwd" :color red)            ("F" (jao-player-seek -10) "seek bwd" :color red))           "Browse"           (("b" jao-player-browse "browse") | 
