Req CurrentItem and NumItem for Grouplist
#1
Is there a way to get the current item and total number of items for a content in a grouplist?
 
Reply
#2
(2015-04-11, 12:13)Eddage Wrote: Is there a way to get the current item and total number of items for a content in a grouplist?
Container(id).NumItems and Container(id).CurrentItem don't work in grouplists ? I know that Container(id).CurrentItem has been fixed in Isengard since it didn't work in previous releases but didn't try for grouplists.

Are you trying to group built-in buttons ? If so, you can still make a simple list with custom items sending clicks to the built-in button id.
[Skin] KOver - V1.1.0 Stable (Repo version)
[WIP] ReKOver - Skinning tool project

If I've been helpful or you like my work, hit "THANK USER" button ;) ...
Reply
#3
As far as I know, nope.

I also searched for a way to display the total number or the current page position a few days ago.
It ended up with a label "scroll down for more" based on the visiblity of a hidden scrollbar.

+1 for this feature.
Main: Lancool II Mesh  - Ryzen 9 5900x - MSI x570 Unify - Zotac RTX 3080 AMP HOLO - 32GB Trident Z Neo 3600 CL16 -  EVO 960 M.2 250GB / EVO 940 250GB / MX100 512GB /  Crucial P1 2TB / WD Blue 3D Nand 2TB 
Sound: Saxx AS30 DSP - Beyer Dynamic Custom One Pro 
TV: Nvidia Shield 2019 Pro- Adalight 114x LEDs - Sony 65XG9505 - Kodi / Emby - Yamaha RX-V683 - Heco Victa 700/101/251a + Dynavoice Magic FX-4
Server: i3 Skylake - 8GB - OMV4 - 22TB Storage
Reply
#4
(2015-04-11, 14:59)sualfred Wrote: As far as I know, nope.

I also searched for a way to display the total number or the current page position a few days ago.
It ended up with a label "scroll down for more" based on the visiblity of a hidden scrollbar.

+1 for this feature.
That make sense having it working in all kind of lists ... +1
[Skin] KOver - V1.1.0 Stable (Repo version)
[WIP] ReKOver - Skinning tool project

If I've been helpful or you like my work, hit "THANK USER" button ;) ...
Reply
#5
(2015-04-11, 14:18)Jayz2K Wrote:
(2015-04-11, 12:13)Eddage Wrote: Is there a way to get the current item and total number of items for a content in a grouplist?
Container(id).NumItems and Container(id).CurrentItem don't work in grouplists ? I know that Container(id).CurrentItem has been fixed in Isengard since it didn't work in previous releases but didn't try for grouplists.

Are you trying to group built-in buttons ? If so, you can still make a simple list with custom items sending clicks to the built-in button id.

It's for things like the video/audio osd settings and context menu so as far as I know there isn't a way around it.

Definitely +1 for this feature to be included though, just wanted to make sure I wasn't missing something!
 
Reply
#6
(2015-04-11, 16:28)Eddage Wrote: It's for things like the video/audio osd settings and context menu so as far as I know there isn't a way around it.

Not yet started OSD skinning. But rebuilt a list with custom items for video window option. It works when using SendClick(id) action in the <onclick> tag ... for a built in contro button.

Seems that you mean the built in grouplist Id="5". Since it's not just button, that won't work as is. Maybe but not sure, using a combination like this in the list item :

Code:
Item 1
<onclick>Control.SetFocus(5,1)</onclick>
<onclick>SendClick(5)</onclick>

Item 2
<onclick>Control.SetFocus(5,2)</onclick>
<onclick>SendClick(5)</onclick>

Etc.
[Skin] KOver - V1.1.0 Stable (Repo version)
[WIP] ReKOver - Skinning tool project

If I've been helpful or you like my work, hit "THANK USER" button ;) ...
Reply
#7
keep in mind that a grouplist can contain a mixture of controls: labels, images, buttons, even disabled buttons and hidden items.
so it's not very straightforward to add those infolabels i think.
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
#8
(2015-04-11, 17:09)ronie Wrote: keep in mind that a grouplist can contain a mixture of controls: labels, images, buttons, even disabled buttons and hidden items.
so it's not very straightforward to add those infolabels i think.

Yep, you're right. But since a pagecontrol<->scrollbar works fine, I would be satisfied to have something like ControlGroup(id).CurrentPage & ControlGroup(id).NumPages Smile
Main: Lancool II Mesh  - Ryzen 9 5900x - MSI x570 Unify - Zotac RTX 3080 AMP HOLO - 32GB Trident Z Neo 3600 CL16 -  EVO 960 M.2 250GB / EVO 940 250GB / MX100 512GB /  Crucial P1 2TB / WD Blue 3D Nand 2TB 
Sound: Saxx AS30 DSP - Beyer Dynamic Custom One Pro 
TV: Nvidia Shield 2019 Pro- Adalight 114x LEDs - Sony 65XG9505 - Kodi / Emby - Yamaha RX-V683 - Heco Victa 700/101/251a + Dynavoice Magic FX-4
Server: i3 Skylake - 8GB - OMV4 - 22TB Storage
Reply
#9
(2015-04-11, 17:55)sualfred Wrote:
(2015-04-11, 17:09)ronie Wrote: keep in mind that a grouplist can contain a mixture of controls: labels, images, buttons, even disabled buttons and hidden items.
so it's not very straightforward to add those infolabels i think.

Yep, you're right. But since a pagecontrol<->scrollbar works fine, I would be satisfied to have something like ControlGroup(id).CurrentPage & ControlGroup(id).NumPages Smile

+1 for this. For e.g. would be very useful to show up/down indicators that there are more items off page.
Arctic Fuse - Alpha now available. Support me on Ko-fi.
Reply
#10
Bit late to the party, but shouldn't Container(id).HasNext / HasPrevious work for this?
Always read the online manual (wiki), FAQ (wiki) and search the forum before posting.
Do not PM or e-mail Team-Kodi members directly asking for support. Read/follow the forum rules (wiki).
Please read the pages on troubleshooting (wiki) and bug reporting (wiki) before reporting issues.
Reply
#11
(2015-08-06, 12:51)mkortstiege Wrote: Bit late to the party, but shouldn't Container(id).HasNext / HasPrevious work for this?

correct, they work pefectly fine for grouplists.
Donate: https://kodi.tv/contribute/donate (foundation), 146Gr48FqHM7TPB9q33HHv6uWpgQqdz1yk (BTC personal)
Estuary: Kodis new default skin - ExtendedInfo Script - KodiDevKit
Reply
#12
http://mirrors.kodi.tv/test-builds/win32...labels.exe is a testbuild (based on todays master) that adds grouplist support for CurrentItem and NumItems. Right now it only considers items as valid that are Visible and Focusable.

Would love to get some feedback Wink
Always read the online manual (wiki), FAQ (wiki) and search the forum before posting.
Do not PM or e-mail Team-Kodi members directly asking for support. Read/follow the forum rules (wiki).
Please read the pages on troubleshooting (wiki) and bug reporting (wiki) before reporting issues.
Reply
#13
Working for me apart from the current item offset is one out. ie item 1 is labelled 0, item 2 is labelled 1, etc.
Reply
#14
Ah right, mkorstiege already noticed that, but I talked him out of correcting that. Obviously I was mistaken with Container.Position which does start with 0.
Reply
#15
Updated the item offset and PR'd @ https://github.com/xbmc/xbmc/pull/7768
Always read the online manual (wiki), FAQ (wiki) and search the forum before posting.
Do not PM or e-mail Team-Kodi members directly asking for support. Read/follow the forum rules (wiki).
Please read the pages on troubleshooting (wiki) and bug reporting (wiki) before reporting issues.
Reply

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