2020-07-06, 00:05
I have a an addon that generates music playlists. Works nicely, and I can either run it through cumbersome menu access to addons, or easily using a keymap (~/.kodi/userdata/keymaps/keyboard.xml):
<keymap>
<global>
<keyboard>
<q mod="ctrl">Quit()</q>
<m mod="ctrl">RunScript(script.audio.playlistgenerator)</m>
</keyboard>
</global>
</keymap>
The question is, given how cumbersome this extra install effort is, can the addon use a setting (in settings.xml) that defines a key, to add it to the keymap itself (and change it if the setting changes)?
Haven't found a way to do that yet in the python API or Builtins. But maybe I missed it or it's trikier?
<keymap>
<global>
<keyboard>
<q mod="ctrl">Quit()</q>
<m mod="ctrl">RunScript(script.audio.playlistgenerator)</m>
</keyboard>
</global>
</keymap>
The question is, given how cumbersome this extra install effort is, can the addon use a setting (in settings.xml) that defines a key, to add it to the keymap itself (and change it if the setting changes)?
Haven't found a way to do that yet in the python API or Builtins. But maybe I missed it or it's trikier?