Autofilling containers and <content>
#1
In the List example: http://kodi.wiki/view/Kodi_Skinning_Manu..._Container - where is the example supposed to take list contents from? Is there some way to set contents for a window being activated?

And related - is it possible for <content> in list to accept variable value - like Window(home).Property(some_prop)? I want list contents to be dependent on a control selected in calling window - on selection I set some_prop to the value that defines list contents.
Reply
#2
http://kodi.wiki/view/Opening_Windows_and_Dialogs
Essentially, the path section in that wiki page is what the viewtype lists for MyVideoNav MyMusicNav etc. will be filled with.
So ActivateWindow(Videos,videodb://movies/titles) is (sort of) the same as having a list control with:
<content>videodb://movies/titles</content>

The big difference with MyVideoNav etc is that you can navigate to other paths, and you can also use the filter and sorting buttons in those windows to alter how the content is display, and use the viewtype selection to cycle through viewtype ids defined in the <views> tags.

You can see what path the list is being filled with by using $INFO[Container.FolderPath] in an external label control.

Yeah, you can use $VAR[SomeVariable] or $INFO[Skin.String(SomeString)] or $INFO[Window(Home).Property(SomeProperty)] in dynamic <content> tags
Arctic Fuse - Alpha now available. Support me on Ko-fi.
Reply
#3
Quoting from the link: "Some windows allow you to jump directly to a sub-section of that window." - that means "build in windows only"?

As for the views, I have not got to them yet, but as far as I can tell from Estuary, you just include all the views into fe. MyVideoNav and just switch some property (?) to make controls of one of the views visible, right?
Reply
#4
Yeah that is for all the built-in MyXXXX windows (plus AddonBrowser which for some reason doesn't follow the naming scheme...)

You are correct about just including them in the corresponding window.
Each view id (of the list/panel control) is defined in the <views> tag in the window definitions.

Button id "2" is a built-in button that cycles visibility for each view id (which is the same as the command Container.NextViewMode, but button id 2 has an automatically filled label that tells you what viewtype is currently selected). You can then use Control.IsVisible(ID) to define what other elements should be visible along with the corresponding list control (e.g. you might want a separate big poster or box with info/plot etc.).

Each viewtype container usually has its own <visible> tags to define the conditions in which it should or should not be available.
e.g. <visible>Container.Content(tvshows)</visible> so that it is only used for tvshows content and not movies or genres etc.
Arctic Fuse - Alpha now available. Support me on Ko-fi.
Reply
#5
(2017-04-07, 23:57)baza_dwa Wrote: As for the views, I have not got to them yet, but as far as I can tell from Estuary, you just include all the views into fe. MyVideoNav and just switch some property (?) to make controls of one of the views visible, right?

That's just one way you can do it, doesn't means it's the only way because estuary does it!
SKIN: Aeon Madnox
RIP Schimi2k, we miss you.
When I grow up I want to be a skilled skinner
Thank me by ⬇ adding to my + reputation
Reply
#6
(2017-04-09, 17:30)Mike_Doc Wrote:
(2017-04-07, 23:57)baza_dwa Wrote: As for the views, I have not got to them yet, but as far as I can tell from Estuary, you just include all the views into fe. MyVideoNav and just switch some property (?) to make controls of one of the views visible, right?

That's just one way you can do it, doesn't means it's the only way because estuary does it!


Yeah, right. 85% of time I spend on skinning is determining how things work because of incomplete and badly written "documentation" plus lack of DTD for Kodi's xml plus lack of any sane skin problem logging. Therefore I accept first working method and have no incentive to look any further. I'd like a skin running, not getting a masters in Kodi skinning.

BTW, do you know how I can use <constant>'s value for <label>'s info/label/number element?

Below I have in Home.xml, and DepthDialog is defined in Estuary (which is my base-so I assume it's set up correctly):
Code:
<control type="label"><number>DepthDialog</number><top>100</top><left>100</left><height>100</height><width>300</width></control>

This is just a test control, my goal is to use constants instead of numbers in ActivateWindow() for custom windows.
Reply
#7
(2017-04-09, 22:40)baza_dwa Wrote:
(2017-04-09, 17:30)Mike_Doc Wrote:
(2017-04-07, 23:57)baza_dwa Wrote: As for the views, I have not got to them yet, but as far as I can tell from Estuary, you just include all the views into fe. MyVideoNav and just switch some property (?) to make controls of one of the views visible, right?

That's just one way you can do it, doesn't means it's the only way because estuary does it!


Yeah, right. 85% of time I spend on skinning is determining how things work because of incomplete and badly written "documentation" plus lack of DTD for Kodi's xml plus lack of any sane skin problem logging. Therefore I accept first working method and have no incentive to look any further. I'd like a skin running, not getting a masters in Kodi skinning.

BTW, do you know how I can use <constant>'s value for <label>'s info/label/number element?

Below I have in Home.xml, and DepthDialog is defined in Estuary (which is my base-so I assume it's set up correctly):
Code:
<control type="label"><number>DepthDialog</number><top>100</top><left>100</left><height>100</height><width>300</width></control>

This is just a test control, my goal is to use constants instead of numbers in ActivateWindow() for custom windows.


I maybe speaking out of turn or maybe I missed read what your trying to say. But the badly written "documentation" is actually a lot better then most other programing languages form my stand point. I have no prior knowledge of computer programing... I am electrician by trade and have some knowledge of PLC controls but that was limited to a semester in college. I started from scratch here making a mod or to with a lot of help from other here on this site. the community is awesome in my opinion and very willing to help if you ask the right questions and put in the time to read the documentation. http://kodi.wiki/view/XBMC_Skinning_Manual this should be your best friend it will tell you everything you need to know as long as you try to understand it.

Different add-on will have there own documentation along with a support thread for most. And again there are a lot of great people here willing to help... but with that remember this is open source and everything that is provided is because someone dedicated there personal time to type it up and edit the website or what not no one here is getting paid so where it my lack some things, if you feel the need to complain about it maybe you should spend the time to fix it and make it better.

Don't be apart of the problem be a part of the solution.

And no I don't have an answer for you issues my apologies for that, but the Kodi team and all developers here deserves more respect then what they get . IMHO.
Shield TV | Windows 10 | Mariadb | Mii Box
Evolve Ecosystem Repo | TV Melodies | Madnox Holiday Mod
Reply
#8
(2017-04-10, 00:54)smitchell6879 Wrote: Don't be apart of the problem be a part of the solution.

Sure, here I am - guys, publish DTD for Kodi's XMLs!

And if you wonder where the 85% comes from: http://forum.kodi.tv/showthread.php?tid=...pid2567425

You've had a hell of hard life if you see Kodi skinning doc "a lot better then most other programing languages", even regarding your standpoint.
Reply
#9
(2017-04-08, 05:24)jurialmunkey Wrote: Yeah that is for all the built-in MyXXXX windows (plus AddonBrowser which for some reason doesn't follow the naming scheme...)


Why then the MyVideoNav below shows nothing, called with a path?


Code:
<?xml version="1.0" encoding="utf-8" ?>
<window>
    <views>50,51,52,53,54,55,500,501,502</views>
    <menucontrol>9000</menucontrol>
    <controls>
        <include>DefaultBackground</include>
        <control type="list">
            <width>500</width>
            <height>500</height>
            <viewtype>list</viewtype>
            <orientation>vertical</orientation>
            <itemlayout width="500" height="50">
                <control type="label">
                    <info>ListItem.Label</info>
                </control>
            </itemlayout>
            <focusedlayout width="500" height="50">
                <control type="label">
                    <info>ListItem.Label</info>
                </control>
            </focusedlayout>
        </control>
    </controls>
</window>
Reply
#10
No ID defined for the list control. Plus your <views> tag is defining IDs that are clearly not available.

Need
<views>50</views>
and
<control type="list" id="50">

Button control ID 2 cycles which list/panel id is visible as defined in the <views> tag.
Arctic Fuse - Alpha now available. Support me on Ko-fi.
Reply
#11
(2017-05-07, 13:41)jurialmunkey Wrote: No ID defined for the list control. Plus your <views> tag is defining IDs that are clearly not available.

Need
<views>50</views>
and
<control type="list" id="50">

Button control ID 2 cycles which list/panel id is visible as defined in the <views> tag.

Thanks. BTW, this is not enumerated in 16.1.47 MyVideoNav.xml in the Skinning Manual.

Anyway, I cannot see button with id=2 in MyVideoNav in lots of skins, and in some it does nothing (no onclick action, fe. in Arctic Zephyr - in fact I cannot find any such button that does something in all the official skins).
Is this button supposed to support Container.NextViewMode function? What should be its onclick action?
Reply
#12
<views> is discussed in the Window Header section, because that is what it is part of.
http://kodi.wiki/view/Skinning_Manual#Window_Header

Button ID 2 is a built in button so its onclick is built in, so onclick is not specified (it definitely does something in Arctic Zephyr -- it changes the viewtype!). Its label tells what view mode is selected using the label specified in the <viewtype label="label"> tag of the corresponding list control. All the built in controls and what they do for each window are documented in the wiki
http://kodi.wiki/view/Skinning_Manual#MyVideoNav.xml
Arctic Fuse - Alpha now available. Support me on Ko-fi.
Reply
#13
(2017-05-07, 14:57)jurialmunkey Wrote: <views> is discussed in the Window Header section, because that is what it is part of.
http://kodi.wiki/view/Skinning_Manual#Window_Header

Button ID 2 is a built in button so its onclick is built in, so onclick is not specified (it definitely does something in Arctic Zephyr -- it changes the viewtype!). Its label tells what view mode is selected using the label specified in the <viewtype label="label"> tag of the corresponding list control. All the built in controls and what they do for each window are documented in the wiki
http://kodi.wiki/view/Skinning_Manual#MyVideoNav.xml

You mean the below is the discussion or there is something more I am not finding:?
Quote:views - This tag lets you use view id's beyond 50 to 59 it also lets you set the order in which they cycle with the change view button in the skin. Only useful in My<Foo>.xml windows.

Also i consider this description:
Quote:2 button Select viewtype (list, thumbnail, media info, etc...)
to be grossly incomplete.

Does onclick for id=2 button or Container.NextViewMode simply activates control with next ID as provided in <views>?
The below is button ID 2 from Arctic Zephyr's MyVideoNav - it doesn't have any label... So what does onclick actually do?
Do you mean the list display control should have both correct ID set (understandable) and viewtype (I assume IDs are in 1:1 relation to the list in 6.24.2 and they should match)? Then how viewtypes out of list in 6.24.2 are added - ID to the <views>, and name?
Code:
<control type="button" id="2">
  <description>View</description>
  <radioposx>400</radioposx>
  <width>450</width>
  <height>70</height>
  <font>Tiny</font>
  <textcolor>Black70</textcolor>
  <textureradiofocus colordiffuse="Black70">buttons/radio-on.png</textureradiofocus>
  <textureradionofocus colordiffuse="Black30">buttons/radio-off.png</textureradionofocus>
  <focusedcolor>Selected</focusedcolor>
  <alttexturefocus colordiffuse="$VAR[ColorHighlight]" border="16">common/white.png</alttexturefocus>
  <texturefocus colordiffuse="$VAR[ColorHighlight]" border="16">common/white.png</texturefocus>
  <align>left</align>
  </control>

And skinning doc simply sucks.
Reply
#14
So, what have you done to improve the docs?
Reply
#15
(2017-05-07, 22:50)Jeroen Wrote: So, what have you done to improve the docs?

Are you sure I am the right person to do this? Even if I can see what is missing, it doesn't mean I know how the missing places should be filled.


BTW, a good example of how the things go: new in v18 https://github.com/xbmc/xbmc/pull/10730 - do you see a tick at "I have updated the documentation accordingly"?...
Reply

Logout Mark Read Team Forum Stats Members Help
Autofilling containers and <content>0