emms-help
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [emms-help] [patch] Browser: look for covers only when displaying al


From: Yoni Rabkin
Subject: Re: [emms-help] [patch] Browser: look for covers only when displaying albums
Date: Thu, 30 Mar 2017 13:36:31 -0400
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/25.2 (gnu/linux)

Cédric Chépied <address@hidden> writes:

> Hi,
>
> I'm using a sshfs music directory with an poor 6 Mb/s connection. When I open
> the browser (by genre for example) it takes several minutes to display all my
> collection because it is looking for covers for each element.
>
> I made this patch so the browser looks for covers only when it is displaying 
> an
> album item and so my emacs is not stuck when I want to listen some music.

This looks like a good change. I don't use the browser so I haven't hit
this issue. Thank you for the patch.

Rasmus, does this patch make sense to you? Someone who uses the browser
should weigh-in before it gets installed.

> Regards,
> -- 
> Cédric Chépied
> <address@hidden>
>
>
>>From c125f7f52db0597485e30fc4546703985cfd649c Mon Sep 17 00:00:00 2001
> From: =?UTF-8?q?C=C3=A9dric=20Ch=C3=A9pied?= <address@hidden>
> Date: Thu, 30 Mar 2017 14:29:57 +0200
> Subject: [PATCH] Browser: look for covers only when displaying albums
>
> ---
>  lisp/emms-browser.el | 16 ++++++++++------
>  1 file changed, 10 insertions(+), 6 deletions(-)
>
> diff --git a/lisp/emms-browser.el b/lisp/emms-browser.el
> index 23b1495..ad6b326 100644
> --- a/lisp/emms-browser.el
> +++ b/lisp/emms-browser.el
> @@ -1751,13 +1751,17 @@ If > album level, most of the track data will not 
> make sense."
>              ("C" . ,(emms-track-get track 'info-composer))
>              ("p" . ,(emms-track-get track 'info-performer))
>              ("t" . ,(emms-track-get track 'info-title))
> -         ("D" . ,(emms-browser-disc-number track))
> +            ("D" . ,(emms-browser-disc-number track))
>              ("T" . ,(emms-browser-track-number track))
> -            ("d" . ,(emms-browser-track-duration track))
> -            ("cS" . ,(emms-browser-get-cover-str path 'small))
> -            ("cM" . ,(emms-browser-get-cover-str path 'medium))
> -            ("cL" . ,(emms-browser-get-cover-str path 'large))))
> -         str)
> +            ("d" . ,(emms-browser-track-duration track))))
> +            str)
> +
> +    (when (equal type 'info-album)
> +      (setq format-choices (append format-choices
> +                                   `(("cS" . ,(emms-browser-get-cover-str 
> path 'small))
> +                                     ("cM" . ,(emms-browser-get-cover-str 
> path 'medium))
> +                                     ("cL" . ,(emms-browser-get-cover-str 
> path 'large))))))
> +
>  
>      (when (functionp format)
>        (setq format (funcall format bdata format-choices)))

-- 
   "Cut your own wood and it will warm you twice"



reply via email to

[Prev in Thread] Current Thread [Next in Thread]