Posts: 219
Joined: Feb 2012
Reputation:
0
In MyMusicNav.xml I have writen:
<onload condition="isVisible(51)">Control.SetFocus(51,2)</onload>
That means I want that when the songs are visible in list panel container , highlight 2nd item of list.
2nd item is 1st song in the view because 1st item is ".." .
I want instead of ".." the item next to ".." should be highlighted when ever the window opens.
Control.SetFocus(51,2) is not working.
51 is id of panel container.
how can I do that?
Thanks of help.
Posts: 5,292
Joined: Jun 2006
Reputation:
62
Jezz_X
Team-XBMC Skinner
Posts: 5,292
You do know that this is going to screw with people who actually go and turn off the show parent items thing right ? not to mention when you go to full screen playback and back again you will lose the current focus
Posts: 219
Joined: Feb 2012
Reputation:
0
Then how can we do it Jezz_x?
I don't understand why this function is not working ?
Control.SetFocus(51,2)
is it for any other purpose?
Thanks for Help.
Posts: 3,956
Joined: Dec 2008
Reputation:
62
Try just setfocus. (without control. )
Posts: 17,415
Joined: Aug 2007
Reputation:
590
Hitcher
Team-Kodi Member
Posts: 17,415
2012-04-16, 17:16
(This post was last modified: 2012-04-16, 17:16 by Hitcher.)
I know my method works with no problems because I tested it.
Posts: 17,415
Joined: Aug 2007
Reputation:
590
Hitcher
Team-Kodi Member
Posts: 17,415
It'll only work if CommonRootView_Info is the first view you see when opening Music, if drill down deeper into the folders (ie Albums, Songs) it wont because MyMusicNav is already open.
Posts: 219
Joined: Feb 2012
Reputation:
0
I agree but it is not working even first time when CommonRootView_Info is the first view.
Also when drill down deeper into the folders (ie Albums, Songs) I want it to work in the same way ,
this will not work here because of <onload> because window is already loaded but then there should be some other way.
Thank You.
Posts: 17,415
Joined: Aug 2007
Reputation:
590
Hitcher
Team-Kodi Member
Posts: 17,415
Best to forget about it and let the user decide if they want to hide the parent folder item altogether.
Posts: 2,441
Joined: Apr 2009
Reputation:
73
`Black
Team-Kodi Member
Posts: 2,441
Why do you want to force users to have ".." hidden? You shouldn't do that, everyone can disable it in the settings if he doesn't need it. Just add this to your skin description that you have your own buttons for going back and users should hide parent folder items if they want the best skin experience.
Posts: 219
Joined: Feb 2012
Reputation:
0
2012-04-18, 06:38
(This post was last modified: 2012-04-18, 06:47 by slinuxgeek.)
OK `Black .
Oh wait this thread was not about hiding the ".." item but , it was about how to highlight the first actual item when user enters the window.
instead of highlighting ".." the item next to ".." should be focused / highlighted .
If ".." is not there (hidden by user) no problem , the first actual item should be focused always.
Please help , I need it.