Kodi Community Forum

Full Version: Boolean conditions for skins to determine if it's a pvr build
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2 3
Is it possible to get a boolean for skins to use if the xbmc build is a pvr build. I want to use it to hide the livetv settings for regular xbmc builds while maintaining the pvr xml's in the skin.
I know I can use a skin setting for that, but imo that would make no sense to put it somewhere in the skinsettings to enable livetv.
+1 for this

Makes sense to me and would be a worthwile addition!

mad-max
maybe you can just add the option to activate livetv or not in the parameters?
like confluence or influence do
Confluence has separate skins for pvr and non-pvr and can do this because it's delivered with the program build itself, something not yet possible for other skins because there's no separate pvr addon branch. I don't know influence, but if by parameters you mean skin settings I think I already explained myself in the first post for that.
I used <visible>System.GetBool(pvrmanager.enabled)</visible> for XeeBo which has PVR in the main skin.
(2012-03-16, 16:26)Hitcher Wrote: [ -> ]<visible>System.GetBool(pvrmanager.enabled)</visible>

Does not work to hide the settings, because that boolean is set in the settings for live tv Wink
Nothing will probably work unless it's also back ported to the main branch. Because the condition will always fail on the normal builds
It fails thus it's not true and any PVR stuff remains hidden, no?
It will generate a error in the normal builds, but will never return true, so it will do what we want. And as long as you don't use it as a visible condition, but only with conditional includes, the log won't be spammed with errors.
I think we've well-lost the usefulness of the "error" in the log - your thoughts?
Could be useful if you made a typo, but with PVR builds in mind I'd rather see it go. Then again, if there was a System.PVR in both pvr and normal builds we could use that instead of reading guisettings. All other pvr related settings are normally loaded in pvr xml's and are never loaded in regular builds, so no errors will be generated. In that case the error logging could stay.
I'll make pvrmanager.enabled a valid setting in Eden (returning false, ofcourse). Sound good?
That doesn't work to hide the LiveTV settings in regular builds (otherwise the settings will be hidden for everybody, because the setting to set pvrmanager.enabled to true is in the livetv settings), but could be useful for skins that have that as a visiblitiy condition in the home window.
Right, you mean a settings category on the main settings screen - will discuss with opdenkamp.
Ok, the setting pvrmanager.enabled will return false (and not spam the log) in Eden.

Also, system.haspvr is now available (infobool) in Eden for switching items off that don't belong.

6e91544 has the goodies.

Cheers,
Jonathan
Pages: 1 2 3