Different FileBrowser layout depending on content
#1
I'm wondering if its possible to have different layouts for FileBrowser.XML subject to the content your browsing. In other words, when browsing for subtitles the user gets a text list, if browsing for thumbs or fanart you get a panel of images.

I've tried conditional visibility, but because both controls have the same id "450" it appears to cause problems even if I hide one of them. Can anyone please help.

Thanks
Reply
#2
That's how it already works - list 450 is non-thumb and list 451 is for thumbs.
Reply
#3
And xbmc decides if its thumbs or not (and which container to display) by what percent of the files are thumbable media
Reply
#4
Great thanks guys. I tried using 451 but only on the list. It hadn't occurred to me that it needed to be the thumbs that were 451. All working great now and thanks again for your help. It's very much appreciated.
Reply
#5
Okay another question which hopefully isn't as obvious as the last. Is it possible to affect which controls are visible based on the previous control? What I'm after is a way to determine whether the FileBrowser will be displaying posters or Fanart? I have two buttons on the VideoInformation window one to change the poster, the other to change the Fanart. I'd like to be able to display different UI's depending on which button the user selected.

I see that there are boolean conditions for Window.Next(window) / Window.Previous(window) and I was wondering whether there was something like Control.Next(control) / Control.Previous(control)? If not is there a way to achieve what I'm after using what’s currently available?
Reply
#6
What about banners vs posters? Seems easier to go with generic layout.
My skins:

Amber
Quartz

Reply
#7
Check out reFocus. You can determine posters or fanarts by string comparing the dialog title.
Image
Reply
#8
Actually I'm not using that bit anymore, but yeah you can do a stringcompare on the path label or dialog title. Unfortunately there's no way to distinguish posters from banners.
Reply
#9
You could set a property when clicking an image (poster/banner/fanart) button and then use a conditional include for the list based on property.
Reply
#10
Great thanks guys. Hitcher could you please give me an example as I'm not too sure what you mean? Also final question (I hope). Is it possible to bring up the change poster/fan art from a dialog or do the buttons have to live on the VideoInfo window? What I'd like is to being up a dialog with options to play, change poster, change fan ar but I'm not sure that this is possible because how do I assign the button ID's?
Reply
#11
CloudDweller Wrote:Is it possible to bring up the change poster/fan art from a dialog or do the buttons have to live on the VideoInfo window? What I'd like is to being up a dialog with options to play, change poster, change fan ar but I'm not sure that this is possible because how do I assign the button ID's?

Code:
<onclick>SendClick(2003,[i]n[/i])</onclick>

would probably work, where n is the button's ID
Reply
#12
Great thanks Jeroen I'll give this a try over the weekend. Love reFocus by the way, truely one of the best skins available for XBMC.
Reply
#13
Hitcher Wrote:You could set a property when clicking an image (poster/banner/fanart) button and then use a conditional include for the list based on property.

Okay I've set the property as follows

Posters
<onclick>SetProperty(VideoInfo,1[,2003])</onclick>

Fan Art
<onclick>SetProperty(VideoInfo,2[,2003])</onclick>

Episode Thumbs
<onclick>SetProperty(VideoInfo,2[,2003])</onclick>

But I'm not sure what exactly I need to type to read the property and display the correct label. This is what I've got so far but its not working.

<visible>Window.IsVisible(2003) + StringCompare(Window(2003).Property(VideoInfo.1),true)</visible>
Reply
#14
remove the square brackets, eg:
Code:
<onclick>SetProperty(VideoInfo,1,2003)</onclick>
and use a stringcomare to check the windowproperty:
Code:
<visible>StringCompare(Window.Property(VideoInfo),1)</visible>
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
#15
Thanks Ronie but that didn't work. I tried <visible>StringCompare(Window(2003).Property(VideoInfo),1)</visible> but that also didn't work.
Reply

Logout Mark Read Team Forum Stats Members Help
Different FileBrowser layout depending on content1