Kodi Community Forum

Full Version: How to create shortcut for "Favorites"
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
How can I create a shortcut for "Favorites" or a menu item for it?
Context Menu on the item you want to add to favorites. If you want to add it to the main menu, depending on the skin your using, this step can vary
Thank you, saitoh183,

And sorry for bad expression. What I meant was, how can I create a shortcut, so press two or more keys of the keyboard at the same time to open the "Favorites" file list, so that I can see the favorites I added before.
Create a custom keyboard.xml (wiki) file in your userdata (wiki)/keymaps/ directory with the following contents:
Code:
<keymap>
  <global>
    <keyboard>
      <some-key>ActivateWindow(Favourites)</some-key>
    </keyboard>
  </global>
</keymap>
  • Substitute "some-key" with the name of the key you wish to assign to this function. Obviously, it should be a key that's not already used by XBMC. The function keys (F1-F12) are good candidates.
  • If you already have a custom keyboard.xml file in your userdata (wiki)/keymaps/ directory, just add the key assignment statement to the <global> section of your existing file.
Many thanks, artrafael,

Yes, I already had such file, I did it like that and it works:

Code:
<keymap>
  <FullscreenVideo>
    <keyboard>
    <b mod="ctrl">ActivateWindow(VideoBookmarks)</b>
      <b>RunScript(C:\Users\Dirk\AppData\Roaming\XBMC\userdata\setbookmark.py)</b>
    </keyboard>
  </FullscreenVideo>
  <VideoOSD>
    <keyboard>
      <b>RunScript(C:\Users\Dirk\AppData\Roaming\XBMC\userdata\setbookmark.py)</b>
      <b mod="ctrl">ActivateWindow(VideoBookmarks)</b>
    </keyboard>
  </VideoOSD>
  
  <global>
    <keyboard>
      <numpadone>LastPage</numpadone>
      <numpadthree>PageDown</numpadthree>
      <numpadseven>FirstPage</numpadseven>
      <numpadnine>PageUp</numpadnine>
      <f mod="ctrl">ActivateWindow(Favourites)</f>
    </keyboard>
    
  </global>
</keymap>

Great, many thanks again.