Kodi Community Forum
find the window id for the "recently added movies" widget to add a keymap for it - Printable Version

+- Kodi Community Forum (https://forum.kodi.tv)
+-- Forum: Support (https://forum.kodi.tv/forumdisplay.php?fid=33)
+--- Forum: Skins Support (https://forum.kodi.tv/forumdisplay.php?fid=67)
+---- Forum: Rapier (https://forum.kodi.tv/forumdisplay.php?fid=120)
+---- Thread: find the window id for the "recently added movies" widget to add a keymap for it (/showthread.php?tid=363567)



find the window id for the "recently added movies" widget to add a keymap for it - ralfonat - 2021-07-14

hey there,

does anyone have a quick tip for me how to identify the current window/dialog id? I'm using the rapier skin and trying to find the window for the "recently added movies" widget so I can add a keymap for it.

I want to be able to select a movie and directly play the trailer for it. I have the action ready for it.

To clarify, I am talking about the recently added movies widget in the "movies" section.

Many thanks in advance.


RE: find the window id for the "recently added movies" widget to add a keymap for it - Gade - 2021-07-30

Hi ralfonat.

Recently added movies library node and the recently added movies widget are two different things.

The widget has a hardcoded path, while the library node has a regular library path.

You can add
 
Code:
ActivateWindow(Videos,videodb://recentlyaddedmovies/,Return)
to your keymaps.

That should take you to the correct window.

Here's a list of some (not all) window paths: https://kodi.wiki/index.php?title=Opening_Windows_and_Dialogs


RE: find the window id for the "recently added movies" widget to add a keymap for it - ralfonat - 2021-08-08

Grade, thanks for your reply!

Sorry but I want to define an action in a keymap when I am navigating in the widget.

So Now I have 

Code:
  <Videos>
    <keyboard>
      <t>RunScript(script.playtrailer)</t>
    </keyboard>
  </Videos>

which allows me to play trailers pressing "T" when I am navigating videos.

Now I want that same functionality within the widget. So I need a window-specify tag.

Using this doesn't seem to work:

Code:
  <recentlyaddedmovies>
    <keyboard>
      <t>RunScript(script.playtrailer)</t>
    </keyboard>
  </recentlyaddedmovies>

Code:
​​​​​​​2021-08-08 07:41:22.110 T:12196   ERROR <general>: Window Translator: Can't find window recentlyaddedmovies



RE: find the window id for the "recently added movies" widget to add a keymap for it - ralfonat - 2021-08-20

(2021-08-08, 07:41)ralfonat Wrote: Grade, thanks for your reply!

Sorry but I want to define an action in a keymap when I am navigating in the widget.

So Now I have 

Code:
  <Videos>
    <keyboard>
      <t>RunScript(script.playtrailer)</t>
    </keyboard>
  </Videos>

which allows me to play trailers pressing "T" when I am navigating videos.

Now I want that same functionality within the widget. So I need a window-specify tag.

Using this doesn't seem to work:

Code:
  <recentlyaddedmovies>
    <keyboard>
      <t>RunScript(script.playtrailer)</t>
    </keyboard>
  </recentlyaddedmovies>

Code:
2021-08-08 07:41:22.110 T:12196   ERROR <general>: Window Translator: Can't find window recentlyaddedmovies
What can I say. It was just the "Home" window after all. There doesn't seem to be a way to target only the "recentlyaddedmovies" ?


RE: find the window id for the "recently added movies" widget to add a keymap for it - jjd-uk - 2021-08-21

@ralfonat I assume you're kongomongo on Github who created this PR https://github.com/xbmc/xbmc/pull/20066

If so then you have missed the fact there's a skin debug overlay available that will tell the window in use. This needs to be added to your keymap for example I have it mapped to F6 key on my keyboard.

xml:
<keymap>
<global>
<keyboard>
<F5>ReloadSkin()</F5>
<F6>Skin.ToggleDebug()</F6>
</keyboard>
</global>
</keymap>



RE: find the window id for the "recently added movies" widget to add a keymap for it - Gade - 2021-08-21

(2021-08-08, 07:41)ralfonat Wrote: Using this doesn't seem to work:

Code:
  <recentlyaddedmovies>
    <keyboard>
      <t>RunScript(script.playtrailer)</t>
    </keyboard>
  </recentlyaddedmovies>

Code:
2021-08-08 07:41:22.110 T:12196   ERROR <general>: Window Translator: Can't find window recentlyaddedmovies

That must be an addon limitation.
The widgets have library paths, but the overall window is Home.

I think you should ask the developer of the script about this.


RE: find the window id for the "recently added movies" widget to add a keymap for it - jjd-uk - 2021-08-21

By the way, just in case you were curious, the F5 entry is to reload the skin is when making code changes to the skin xml files, so reload is necessary for changes to take effect. So nothing to do with what you were asking.