Req CurrentItem and NumItem for Grouplist
#16
Hey,

It seems that Container.NumItems in grouplists ignor disabled buttons?

For example in DialogAddonInfo.xml with 8 items i become with Container.NumItems the value 4.
I use it for different height of the backgroundimage.

Is this an issue or must we disabled inaktiv core buttons with a visible in this situations?

Generel I prefer to see it with the disabledcolor tag and won´t hide it from the menue,
but in this situation the NumItem 4 displays the wrong background texture.

Regards
Reply
#17
I just think that noone has thought of that situation. It is valid suggestion to have the behaviour you want. Now.. to get the attention of a pro and a proper "fix" I cannot help you.
Reply
#18
(2016-05-24, 09:34)Torben Wrote: I just think that noone has thought of that situation. It is valid suggestion to have the behaviour you want. Now.. to get the attention of a pro and a proper "fix" I cannot help you.
Hey,

My workaround is to hide inactive core buttons if they do not disappear by themselves
with the visible.
In complex lists with mixed content like mynavxxx files (sidebars) the control is easier.

But I think its an error of Kodi. Some core buttons always visible with the disabledcolor tag as text
but not counted by container.numitems Infolabel.

When I see 8 buttons on the menue the info should be 8 not 4 because the other 4 are disabledWink

Regards
Reply
#19
numitems returns the number of controls that are both visible & focus-able.

i'll merge this thread with the thread were all this was discussed,
so we can re-evaluate whether the current implementation should be changed or not.
Do not PM or e-mail Team-Kodi members directly asking for support.
Always read the Forum rules, Kodi online-manual, FAQ, Help and Search the forum before posting.
Reply
#20
Imo using NumItems for determining the height of a background image is more or less misuse of that info. You can integrate the background image with the button texture for this usecase (as is done in the shutdown dialog in Confluence for example). If you need a label in that list, you can use a disabled button then for that.
Counting the disabled items makes sense though. They are part of the list and as such should be counted if you want to show the total number of items.
Reply
#21
Thanks for merging and the RepliesBlush.

(2016-05-24, 14:16)BigNoid Wrote: Imo using NumItems for determining the height of a background image is more or less misuse of that info. You can integrate the background image with the button texture for this usecase (as is done in the shutdown dialog in Confluence for example). If you need a label in that list, you can use a disabled button then for that.
Counting the disabled items makes sense though. They are part of the list and as such should be counted if you want to show the total number of items.

Unless for me the workaround with Control.IsEnabled as visible or in the Addoninfo a fix height works also.

Buttons doesent work - the background has a shadow on all borders (top/bottom).
Separatet as two textures, both with color var´s.
Buttons makes trouble with colordiffuse of the textures (the shadows part colored too and with dark colors it doesent work), and in lists with more items than the define
height endtexture comes on the second page.

+1 for the number of elements in a grouplist - active and inactiv items.
Own items normally has a visible conditions and works with the current.
In my opinion core buttons should react in the same way.
When there are visible they should be count.

Regards
Reply
#22
In your case it should work as long as you don't add label controls
Reply
#23
(2016-05-24, 14:45)BigNoid Wrote: In your case it should work as long as you don't add label controls

Thanks for the note. I don´t need labels in this controls, otherwise i make a +1 height
or live without labels.

With the colordiffuse of the button texture, or different textures with shadows it doesent work as well.
So thats the last alternative I think.

Regards
Reply

Logout Mark Read Team Forum Stats Members Help
CurrentItem and NumItem for Grouplist0