Release script.embuary.helper - a (maybe) skin helper service / widgets alternative
#1
FYI and because some other skinners already are using my helper for Embuary in their projects:

script.embuary.helper is somehow comparable to the heavily used Skin Helper Service packages. The main difference is, that it doesn't call any information from the web, which makes it a lot of faster. For sure there are a lot of downsides like no real time Rotten ratings etc, but skinners which are looking for a way to get feature rich widgets or some helper functions are might be interested. 

With Kodi 19 Matrix we will also face the switch from Python 2.7 to Python 3 and I assume - if nobody will take care of it - that the Skin Helper stuff is going to break in the very beginning. I just want to offer you guys another way to get things implemented without having headaches because of a missing or broken dependency. 

Even if the helper was created for Embuary, it should not stop you to using it in other skins. It's available on the official Kodi repo and is already Python 3 ready. A Krypton version is available on my personal one.

I've made a documentation with all features so skinners should easily can see what is possible and what not:

Thread: 345318 (thread)
Wiki and documentation: https://github.com/sualfred/script.embuary.helper/wiki
Embuary | Skin | Helper | Info | Repo | GitHub
Reply
#2
That's awesome.
Reply
#3
(2019-07-17, 10:18)sualfred Wrote: FYI and because some other skinners already are using my helper for Embuary in their projects:

script.embuary.helper is somehow comparable to the heavily used Skin Helper Service packages. The main difference is, that it doesn't call any information from the web, which makes it a lot of faster. For sure there are a lot of downsides like no real time Rotten ratings etc, but skinners which are looking for a way to get feature rich widgets or some helper functions are might be interested. 

With Kodi 19 Matrix we will also face the switch from Python 2.7 to Python 3 and I assume - if nobody will take care of it - that the Skin Helper stuff is going to break in the very beginning. I just want to offer you guys another way to get things implemented without having headaches because of a missing or broken dependency. 

Even if the helper was created for Embuary, it should not stop you to using it in other skins. It's available on the official Kodi repo and is already Python 3 ready. A Krypton version is available on my personal one.

I've made a documentation with all features so skinners should easily can see what is possible and what not:

Thread: 345318 (thread)
Wiki and documentation: https://github.com/sualfred/script.embuary.helper/wiki

Sounds great, did you consider to add a
'checkexist' funtion.


simple example
## -*- coding: utf-8 -*-
import xbmc
import xbmcvfs

trailerfilenamemp4 =  xbmc.getInfoLabel( "listitem.path" ) + xbmc.getInfoLabel( "listitem.FolderName" ) + "-trailer" + ".mp4"

if xbmcvfs.exists(trailerfilenamemp4):
    xbmc.executebuiltin( "SetProperty(trailer_avail,true,home)" )
else:
    pass

(may benefits on other things as well, e.g. i use it for check for local tv show trailers, https://streamable.com/zdr2f )
Reply
#4
@mardukL 
https://github.com/sualfred/script.embua...5db5501a08
https://github.com/sualfred/script.embua...ile-exists

Will be available on the next version bump.
Embuary | Skin | Helper | Info | Repo | GitHub
Reply
#5
(2019-07-17, 14:11)sualfred Wrote: @mardukL 
https://github.com/sualfred/script.embua...5db5501a08
https://github.com/sualfred/script.embua...ile-exists

Will be available on the next version bump.

Great, thanks.
Reply
#6
Yep, been working on transitioning from SH for a while now.
Just keep it simple so it won't become as massive as SH was...

it would be great if the whole package is separated into modules - helper/tools, plugin, service.
This will keep the code smaller, more readable, easy to maintain and a user/skinner would not be bound to install everything.

Anyways, good work as usual man.
Reply
#7
No to modules. Some functions are shared. So there would be no benefit. Don't forget that the script is mainly created for Embuary.
Embuary | Skin | Helper | Info | Repo | GitHub
Reply
#8
Thank you @sualfred ! Your work is greatly appreciated.

Regards,

Bart
Reply
#9
Amazing work.

Thankyou for adding this to the kodi repo.
Reply
#10
@sualfred just started to use this and wanted to ask if it's possible to clear the contents of a list?

I'm using it to display a list of similar TV shows or Movies in the video info dialog but each time I check another item the old list is still cached for a second before the new one loads. If I could clear it when I unload the video info dialog that would be great.
Reply
#11
Not really. This and the caching is handled by Kodi. As long as the same container is updating it won't clear the old existing content. But you could try to play with window props during load/unload of the info screen. If prop is filled -> $VAR[content] returns "-" for example. This will instantly clear it before.
Embuary | Skin | Helper | Info | Repo | GitHub
Reply
#12
Cheers.
Reply
#13
@Hitcher 
Another approach just as suggestion. If you want I can add this window property directly to the script so it always sets a loading property + and clears it once endDirectory is reached.

In DialogVideoInfo.xml
Code:

    <onload>SetProperty(CL,1,home)</onload>
    <onload>AlarmClock(clearCL,ClearProperty(CL,home),00:01,silent)</onload>

Container layout:


                        <itemlayout condition="!String.IsEmpty(Window(Home).Property(CL))">
                                  ---- loading spinner for example ---
                        </itemlayout>
                        <itemlayout condition="String.IsEmpty(Window(Home).Property(CL))" width="257">
                            <control type="group">
                                <left>70</left>
                                <top>64</top>
                                <include content="CastLayout">
                                    <param name="mainlabel" value="$PARAM[mainlabel]" />
                                    <param name="sublabel" value="$PARAM[sublabel]" />
                                    <param name="labels_visible" value="$PARAM[labels_visible]" />
                                    <param name="focused" value="false" />
                                    <param name="id" value="$PARAM[id]" />
                                </include>
                            </control>
                        </itemlayout>
                        <focusedlayout condition="!String.IsEmpty(Window(Home).Property(CL))">
                                  ---- loading spinner for example ---
                        </focusedlayout>
                        <focusedlayout condition="String.IsEmpty(Window(Home).Property(CL))" width="257">
                            <control type="group">
                                <left>70</left>
                                <top>64</top>
                                <include content="CastLayout">
                                    <param name="mainlabel" value="$PARAM[mainlabel]" />
                                    <param name="sublabel" value="$PARAM[sublabel]" />
                                    <param name="labels_visible" value="$PARAM[labels_visible]" />
                                    <param name="focused" value="true" />
                                    <param name="id" value="$PARAM[id]" />
                                </include>
                            </control>
                        </focusedlayout>
Embuary | Skin | Helper | Info | Repo | GitHub
Reply
#14
This is not a request, just a question.

You mentioned in your first post that your helper doesnt get the information from the web which makes it a lot faster and for that reason you would not have live rotten tomatos ratings, etc.

for those of us who have the different ratings stored in our database for movies and tvshows, would you be able to display those ratings in different views and not just dialogvideoinfo using a feature in your helper?
Reply
#15
Sadly not. Afaik there is no way to call them via JSON.
Embuary | Skin | Helper | Info | Repo | GitHub
Reply
 
Thread Rating:
  • 2 Vote(s) - 5 Average



Logout Mark Read Team Forum Stats Members Help
script.embuary.helper - a (maybe) skin helper service / widgets alternative52