mpv-player / mpv

🎥 Command line video player
https://mpv.io
Other
28.66k stars 2.93k forks source link

Revert "input: allow input.conf bindings to be declared as builtin" #15347

Closed guidocella closed 19 hours ago

guidocella commented 22 hours ago

This reverts commit 70ff543029068188a3de39a80a764267c6671e7c.

This never did anything because mp_input_load_config() always already called parse_config() with builtin = true for builtin_input_conf. And we already have compatibility input.conf files without depending on this line. So unless someone can decipher what wm4 meant, it can be removed.

na-na-hi commented 19 hours ago

This never did anything because mp_input_load_config() always already called parse_config() with builtin = true for builtin_input_conf.

This is incorrect. For key bindings loaded from config files rather than builtin_input_conf, this makes the bindings treated as builtin so they have lower priority compared to non-builtin bindings.

guidocella commented 19 hours ago

Ok but we don't have any such config file with that line.

na-na-hi commented 19 hours ago

It can be defined in user's config files.

guidocella commented 19 hours ago

But why would someone do that? It's not even documented.

na-na-hi commented 19 hours ago

But why would someone do that?

It has valid uses. For example, a mpv plugin or script can redefine builtin key bindings, without needing to recompile mpv, while still allowing user bindings in input.conf take preference. It allows changing player key bindings in a less agressive way.