Guest - Testers are needed for the reworked CDateTime core component. See... https://forum.kodi.tv/showthread.php?tid=378981 (September 29) x
  • 1
  • 20
  • 21
  • 22(current)
  • 23
  • 24
  • 28
Release script.embuary.helper - a skin helper service / widgets alternative
Yea, that makes sense. Kinda stupid of me but i was hoping that will work the same way like the global search RunScript action. Sorry.

Another question, lets we have about 5-6 items in the created dialog, is there a way to hide based on a condition one of those in the middle?. I mean if the Dialog.3.xxxx or Dialog.4.xxxx if for example entries are running some script actions hide them if the script it's not installed. Currently i am installing these scripts if they are not installed with actions in beginning but i would like to hide them if is possible. 

Cheers
Nessus
Reply
@nessus 

It's been a while since I've added it, but afair this should work:

Code:

<onclick condition="!System.HasAddon(script.globalsearch)">SetProperty(Dialog.1.Label,-,Home)</onclick>
<onclick condition="System.HasAddon(script.globalsearch)">SetProperty(Dialog.1.Label,$LOCALIZE[3],Home)</onclick>
<onclick condition="System.HasAddon(script.globalsearch)">SetProperty(Dialog.1.Label2,$LOCALIZE[31381],Home)</onclick> <onclick>SetProperty(Dialog.1.Icon,icons/videos.png,Home)</onclick>
<onclick condition="System.HasAddon(script.globalsearch)">SetProperty(Dialog.1.BuiltIn,RunScript(script.globalsearch,movies=true&amp;tvshows=true&amp;episodes=true&amp;musicvideos=true),Home)</onclick>
<onclick>SetProperty(Dialog.2.Label,Search,Home)</onclick> <onclick>SetProperty(Dialog.2.Label2,$LOCALIZE[31384],Home)</onclick> <onclick>SetProperty(Dialog.2.Icon,icons/search.png,Home)</onclick> <onclick>SetProperty(Dialog.2.BuiltIn,SetProperty(CustomSearch,1,Home)||Skin.Reset(SearchString)||Skin.SetString(SearchString)||ActivateWindow(1125),Home)</onclick> <onclick>RunScript(script.embuary.helper,action=createselect,header=$LOCALIZE[137]...,usedetails=true)</onclick>


You can use "-" or "none" for it.

If you are doing it for Matrix be sure you use System.AddonIsEnabled()
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
@sualfred

I want to make the jump to this add-on but there is one skin.helper.service feature that would sorely be missed if I did. Hope you will consider adding this feature to embuary helper.

Quote:SkinHelper.AutoCloseMusicOSD
Auto close the Music OSD panel when activated by the user after number of seconds (0 or empty disables this)

Skin.SetNumeric(SkinHelper.AutoCloseMusicOSD)

SkinHelper.AutoCloseVideoOSD
Auto close the Video OSD panel when activated by the user after number of seconds (0 or empty disables this)

Skin.SetNumeric(SkinHelper.AutoCloseVideoOSD)
Reply
That's something that could be achieved by using System.IdleTime(ss) and a custom invisible dialog window.

Code:

<?xml version="1.0" encoding="UTF-8"?>
<window type="dialog" id="1116">
    <visible>[Window.IsVisible(musicosd) | Window.IsVisible(videoosd)] + System.IdleTime(30)</visible>
    <onload>Dialog.Close(videoosd)</onload>
    <onload>Dialog.Close(musicosd)</onload>
    <controls/>
</window>
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
(2020-04-08, 10:59)sualfred Wrote: That's something that could be achieved by using System.IdleTime(ss) and a custom invisible dialog window.

Code:

<?xml version="1.0" encoding="UTF-8"?>
<window type="dialog" id="1116">
    <visible>[Window.IsVisible(musicosd) | Window.IsVisible(videoosd)] + System.IdleTime(30)</visible>
    <onload>Dialog.Close(videoosd)</onload>
    <onload>Dialog.Close(musicosd)</onload>
    <controls/>
</window>

Please correct me if I'm wrong but variable substitution is not permitted for integers so how would a user-specified timeout value be achieved in your example.
Reply
You could offer a set of possible integers. Like a range from 5 to 60.

Code:

<?xml version="1.0" encoding="UTF-8"?>
<window type="dialog" id="1116">
    <visible>
        [Window.IsVisible(musicosd) | Window.IsVisible(videoosd)] + [
        [System.IdleTime(30) + String.IsEqual(Skin.String(mytimer),30)]
        | [System.IdleTime(20) + String.IsEqual(Skin.String(mytimer),20)]
        | [System.IdleTime(10) + String.IsEqual(Skin.String(mytimer),10)]
        | [System.IdleTime(5) + String.IsEqual(Skin.String(mytimer),5)]
        ]
    </visible>
    <onload>Dialog.Close(videoosd)</onload>
    <onload>Dialog.Close(musicosd)</onload>
    <controls/>
</window>

or


Code:

<?xml version="1.0" encoding="UTF-8"?>
<window type="dialog" id="1116">
    <visible>
        [Window.IsVisible(musicosd) | Window.IsVisible(videoosd)] + System.IdleTime(1)
    </visible>
    <onload condition="String.IsEqual(Skin.String(mytimer),5)">AlarmClock(closetimer,Dialog.Close(videoosd),00:04,silent)</onload>
    <onload condition="String.IsEqual(Skin.String(mytimer),5)">AlarmClock(closetimer,Dialog.Close(musicosd),00:04,silent)</onload>
    <onload condition="String.IsEqual(Skin.String(mytimer),10)">AlarmClock(closetimer,Dialog.Close(videoosd),00:09,silent)</onload>
    <onload condition="String.IsEqual(Skin.String(mytimer),10)">AlarmClock(closetimer,Dialog.Close(musicosd),00:09,silent)</onload>
    <onload condition="String.IsEqual(Skin.String(mytimer),20)">AlarmClock(closetimer,Dialog.Close(videoosd),00:19,silent)</onload>
    <onload condition="String.IsEqual(Skin.String(mytimer),20)">AlarmClock(closetimer,Dialog.Close(musicosd),00:19,silent)</onload>
    <controls/>
</window>

Edit:
The reason why I always prefer to use a skin method like this is that each service and continuously Python call for conditions each second is expensive.
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
I'll stick with the other solution. Thanks anyway.
Reply
Hi Smile

I'm using Kodi 18.6 on Android TV with Aeon Tajo skin.

Do embuary.helper works well with path substitution for thumbnails?

I got my thumbs folder in a SMB share due to super low storage on my Android TV, everything seems to work well, but I keep getting this error in the log:
Code:
2020-04-14 00:57:48.800 T:22777 WARNING: [ script.embuary.helper ] Image error: Could not open cached image --> [Errno 2] No such file or directory: '/storage/emulated/0/Android/data/org.xbmc.kodi/files/.kodi/userdata/Thumbnails/5/544a7eea.jpg'
2020-04-14 00:57:48.819 T:22777   DEBUG: CSMBFile::Open - opened smb://USERNAME:PASSWORD@TassPC/Thumbnails Kodi (NO TOCAR)/5/544a7eea.jpg, fd=10001
2020-04-14 00:57:48.849 T:22777   DEBUG: CSMBFile::Close closing fd 10001
It says that it couldn't open a thumb in cache, but next line seems to say that that very same thumb is open.

Reading this log, is embuary.helper working fine in my system and that WARNING line is a mistake, or is it not been able to access my thumbs folder in SMB?

This is the full log: https://paste.kodi.tv/

Thanks a lot!
Reply
You can ignore it. It fails and then it retries with success.
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
@sualfred, I am also in the process of replacing skin helper backgrounds. I know your addon already provides global random backgrounds for movies, tv shows and artists. What I am missing right now are music videos and movie playlists. I tried doing those with hidden lists, but have the issue that if an item in the playlist does not have fanart, then a black background will be shown.

I am trying to have the ability in Amber to select a playlist (only movies) as a background for a menu item, so that it shows random fanart from the movies in the playlist, but skipping any movies with no fanart.

Would you consider adding functionality like this to your addon? Thanks.

Also, would you consider adding the title and logo (if available) of the movie/tv show/artist as window properties for the random backgrounds that the addon provides? I display the title/tv show title/artist name and logo for the backgrounds in Amber.  Thanks.

Regards,

Bart
Reply
@bsoriano 

Check the github version.
Added "EmbuaryBackgroundMusicVideos" plus the suffixes ".Poster", ".Clearlogo", ".Banner", ".Landscape" and ".Title".

For the custom playlist etc I suggest you to use a skin based workaround like in the other thread you are also participating. This will load faster and I don't have to add weird service tasks for it.
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
(2020-04-22, 08:26)sualfred Wrote: @bsoriano 

Check the github version.
Added "EmbuaryBackgroundMusicVideos" plus the suffixes ".Poster", ".Clearlogo", ".Banner", ".Landscape" and ".Title".

For the custom playlist etc I suggest you to use a skin based workaround like in the other thread you are also participating. This will load faster and I don't have to add weird service tasks for it.

@sualfred, thanks! I will test this out today.

I am already providing the playlist background using a hidden list, my issue is that I have not been able to figure out how to skip movies with no fanart. Any ideas for that? Thanks again for your help.

Regards,

Bart
Reply
@bsoriano 
Added a container listing for it. Use it as hidden container.
It only adds items with existing fanart.
Available info labels: ListItem.Label & ListItem.Art(foo)

Example
Code:

<content>plugin://script.embuary.helper?info=getfanartsbypath&amp;path='"special://profile/playlists/video/embymovies92a79c339d509c9cd59a793ac0544c16.xsp"'&amp;reload=$INFO[Window(home).Property(EmbuaryWidgetUpdate)]</content>

Edit:
Btw. It also works for "ActivateWindow(foo)" and splits it automatically
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
(2020-04-22, 11:55)sualfred Wrote: @bsoriano 
Added a container listing for it. Use it as hidden container.
It only adds items with existing fanart.
Available info labels: ListItem.Label & ListItem.Art(foo)

Example
Code:

<content>plugin://script.embuary.helper?info=getfanartsbypath&amp;path='"special://profile/playlists/video/embymovies92a79c339d509c9cd59a793ac0544c16.xsp"'&amp;reload=$INFO[Window(home).Property(EmbuaryWidgetUpdate)]</content>

Edit:
Btw. It also works for "ActivateWindow(foo)" and splits it automatically

@sualfred, this is fantastic, thank you so much! I will be testing in the next couple of hours.

Regards,

Bart
Reply
@sualfred, all of the additions work fantastic, thank you! Smile

The only random backgrounds that are not working are for music.  The home window property is always blank.  Could this be a bug, or do I need to configure something differently? Please let me know.  Thanks.

Regards,

Bart
Reply
  • 1
  • 20
  • 21
  • 22(current)
  • 23
  • 24
  • 28

Logout Mark Read Team Forum Stats Members Help
script.embuary.helper - a skin helper service / widgets alternative3