Why does Container work so strange???

  Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Post Reply
baza_dwa Offline
Member
Posts: 91
Joined: Feb 2017
Reputation: 0
Post: #1
Hello

I have MyVideoNav opened with some contents displayed.
I open a custom dialog from MyVideoNav, and it contains a wraplist inside a group inside a list.
In this wraplist I have (this is my own plugin, so only syntax matters in this case)
Code:
<content>plugin://plugin.stiff?path=$INFO[Container.FolderPath]&fetch=genres</content>

The $INFO part works, fetching FolderPath of main MyVideoNav container (ie. the currently displayed <views> item)

Why is it like thatConfused Accidentally this is what I want, but I really don't like magic like that, as it can stop working any moment. I suspect Container item has some special meaning, as opposed to Container(id) which refers to a specific container.

So far communication between windows was possible for me only with Properties, as there is no way to reference another window in info (even something like like Window(videos).Container.FolderPath doesn't work in the above example).
(This post was last modified: 2017-06-18 15:40 by baza_dwa.)
find quote
jurialmunkey Offline
Skilled Skinner
Posts: 2,303
Joined: Feb 2013
Reputation: 214
Post: #2
Container.FolderPath shows the folderpath (e.g. videodb://movies/titles) of the current library position in MyXXXX windows.
http://kodi.wiki/view/Skinning_Manual#Container_2

All the Container info labels in that list that don't have Container(ID) follow this same logic.
For instance Container.Viewmode / Container.SortMethod / Container.Content will all return values based upon the current library path open in the current MyXXXX window. You can't specify an ID for them.

It's not magic, its supposed to work like this and always has. If it ever gets changed (which I highly doubt), the change will be listed in the thread about "changes to the skinning engine for VERSION" in this forum.

The reason it is like this is because the ability to specify dynamic content for containers is relatively new. It used to be that the only dynamic content available was in the viewmodes for the MyXXXX windows, so Container.FolderPath has always referenced this as other non-viewmode containers couldn't have a folderpath (because they could only have static items)
(This post was last modified: 2017-06-18 15:59 by jurialmunkey.)
find quote
baza_dwa Offline
Member
Posts: 91
Joined: Feb 2017
Reputation: 0
Post: #3
OK, and on the other hand I see, thak Container(id) reference is possible only to control in the same window, right? The properties mechanism being the only generic way to communicate among windows, right?
(This post was last modified: 2017-06-18 20:59 by baza_dwa.)
find quote
jurialmunkey Offline
Skilled Skinner
Posts: 2,303
Joined: Feb 2013
Reputation: 214
Post: #4
Yeah im pretty sure. You can also use skin strings or skin settings between windows as well - difference being those are persistent whereas properties are wiped on restart so depends on use case
find quote