emms-help
[Top][All Lists]
Advanced

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

Re: [emms-help] Use define-*-mode facility? (emms-browser-mode-hook is m


From: Yoni Rabkin
Subject: Re: [emms-help] Use define-*-mode facility? (emms-browser-mode-hook is missing)
Date: Thu, 14 Dec 2017 07:19:12 -0500
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/25.3 (gnu/linux)

Pierre Neidhardt <address@hidden> writes:

> I was wondering why EMMS does not use the `define-*-mode` macros.
> Commands, variables, hooks and maps are defined manually.  Any reason
> for that?

The recommendation to use define-derivative-mode and such was added in
2011, and most of the mode-related code in Emms was written a long time
before that.

That's pretty much the entire reason; just history.

> This leads to inconsistencies.  For instance `emms-browser-mode` does
> not have a mode hook.  I would like to add one, I think it's an
> essential feature.

You can add standard hooks wherever you see that one is missing, since
merely adding a hook can't break any code.

However, you would need to be more careful if you wanted to convert
existing modes to be defined via define-*-mode, for obvious reasons, to
make sure nothing mysteriously breaks.

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



reply via email to

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