summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
-rw-r--r--init.org34
1 files changed, 10 insertions, 24 deletions
diff --git a/init.org b/init.org
index f5008f6..a7f57f3 100644
--- a/init.org
+++ b/init.org
@@ -2945,36 +2945,20 @@
:demand t
:commands jao-mpc-setup)
- (jao-mpc-setup)
-
- (defun jao-mpc-seek-forward () (interactive) (jao-mpc-seek 10))
- (defun jao-mpc-seek-backward () (interactive) (jao-mpc-seek -10))
+ (defvar jao-mopidy-port 6669)
+ (jao-mpc-setup jao-mopidy-port)
(defalias 'jao-player-connect 'jao-mpc-connect)
(defalias 'jao-player-toggle 'jao-mpc-toggle)
(defalias 'jao-player-next 'jao-mpc-next)
(defalias 'jao-player-previous 'jao-mpc-previous)
(defalias 'jao-player-stop 'jao-mpc-stop)
- (defalias 'jao-player-seek-forward 'jao-mpc-seek-forward)
- (defalias 'jao-player-seek-backward 'jao-mpc-seek-backward)
+ (defalias 'jao-player-seek 'jao-mpc-seek)
(defalias 'jao-player-play 'jao-mpc-play)
(defalias 'jao-player-echo 'jao-mpc-echo-current)
(defalias 'jao-player-list 'jao-mpc-show-playlist)
(defalias 'jao-player-browse 'jao-mpc-show-albums)
#+end_src
-*** mopidy
- #+begin_src emacs-lisp
- (defvar jao-mopidy-port 6669)
-
- (defmacro jao-mopidy-def (name args &rest body)
- `(defun ,name ,args
- (interactive)
- (let ((jao-mpc-port jao-mopidy-port)) ,@body)))
-
- (jao-mopidy-def jao-mopidy-show-playlist () (jao-mpc-show-playlist))
- (jao-mopidy-def jao-mopidy-clear () (jao-mpc-clear))
-
- #+end_src
*** hydras
#+begin_src emacs-lisp
(require 'jao-lyrics)
@@ -3017,10 +3001,12 @@
(("s" espotify-play-pause "toggle")
("n" espotify-next "next")
("p" espotify-previous "previous")
- ("w" jao-mpris-show-osd "currently playing"))
+ ("f" (jao-mpc-seek 10 jao-mopidy-port) "seek fwd" :color red)
+ ("F" (jao-mpc-seek -10 jao-mopidy-port) "seek bwd" :color red))
"Browse"
- (("l" jao-mopidy-show-playlist "playing list")
- ("c" jao-mopidy-clear "clear list" :color red)
+ (("l" (jao-mpc-show-playlist jao-mopidy-port) "playing list")
+ ("c" (jao-mpc-clear jao-mopidy-port) "clear list" :color red)
+ ("w" (jao-mpc-echo-current jao-mopidy-port) "currently playing")
("s-s" jao-hydra-spotify/body nil))))
(pretty-hydra-define jao-hydra-media
@@ -3029,8 +3015,8 @@
(("m" jao-player-toggle "toggle")
("n" jao-player-next "next")
("p" jao-player-previous "previous")
- ("f" jao-player-seek-forward "seek fwd" :color red)
- ("F" jao-player-seek-backward "seek bwd" :color red))
+ ("f" (jao-player-seek 10) "seek fwd" :color red)
+ ("F" (jao-player-seek -10) "seek bwd" :color red))
"Browse"
(("b" jao-player-browse "browse")
("l" jao-player-list "show play list")