Release plugin.video.themoviedb.helper - Access to TheMovieDb API for Skinners
(2019-08-24, 01:17)jurialmunkey Wrote:
(2019-08-23, 16:08)bsoriano Wrote: @jurialmunkey , thank you so much! There is no way I would have figured that out.  There is so much for me to learn about animations and the design part of skinning in general.  Removing the condition from the unload works great.
Honestly, I didn't know that about that difference with windowclose animations myself. I was fairly stumped for quite a while as I could see our approaches were functionally equivalent but for some reason Amber wasn't deleting the lock the first time around. It was a process of elimination through knowing exactly how my script works.
(2019-08-23, 17:35)bsoriano Wrote: In you implementation, hidden list 3100 has the details for the person, and an onback from it closes the dialog and goes back to the previous path. Is it necessary to keep the details in that list if they already are in container 9999? I tested and it seems to work. Are there any disadvantages to using the info from container 9999 instead of 3100?
I only use the 3100 list because I limit 9999 to one item to ensure that I'm always getting the first result for dialogvideoinfo. So I need 3100 to get the folder paths for the lists of movies/tvshows that the person was cast/crew in as these are further items in the detailed item list (e.g. Container(3100).ListItemAbsolute(2).FolderPath). Really I could use the direct plugin paths instead - it is just a little simpler to skin it my way because the listitem.folderpath is pre-filled with the correct tmdb_id and other params.
(2019-08-23, 18:24)bsoriano Wrote: I am getting errors in the log related to simplecache when movies and or people have accented characters in the name. The following is an excerpt from my log when looking at person info for Ingrid García-Johnsson from the movie The Little Switzerland.
There were some recent changes made to simplecache to ensure python 3 compatibility. I need to make some changes to the way I manage strings.

Also, I'm not sure why Kodi is complaining that "actor" is not a valid mediatype. It seems that maybe the available dbtypes for a plugin are a bit more limited than what the kodi library has. 
@jurialmunkey , thank you for the explanations! For now I removed the limit from container 9999 in Amber and I am using the folderpaths from it for the different cast lists.  I also made my "..." button the default in the person info dialog.  So far so good.

I added three other cast lists (cast in tv shows, and crew in movies and tv shows) to the person info dialog, but I have not been able to figure out how to not show any that is empty.  If I add Integer.IsGreater(Container(xxx).NumItems,0) | Container(xxx).IsUpdating  as the visibility condition to any of the lists, the list does not show, even if it has items.  I ran into this before with my custom search window and could not figure it out there either.

My code for the lists is this right now (with a workaround to show that a list is empty):
xml:

<control type="group" id="9100">
                <posx>700</posx>
                <posy>600</posy>
                <width>1180</width>
                <height>450</height>
                
                <control type="grouplist" id="91001">
                    <scrolltime tween="quadratic">400</scrolltime>
                    <onup>90003</onup>
                    <height>450</height>
                    <orientation>vertical</orientation>
                    <itemgap>50</itemgap>
                    <usecontrolcoords>true</usecontrolcoords>
                    
                    <control type="group">
                        <height>450</height>
                        <control type="group">
                            <control type="label">
                                <left>8</left>
                                <top>0</top>
                                <height>30</height>
                                <label>Cast in Movies</label>
                            </control>
                            <control type="image" description="Line Split">
                                <top>38</top>
                                <left>10</left>
                                <width>1180</width>
                                <height>1</height>
                                <texture>img/LineL.png</texture>
                                <aspectratio>stretch</aspectratio>
                            </control>
                            <control type="list" id="9101">
                                <top>42</top>
                                <width>1180</width>
                                <height>410</height>
                                <onup>300</onup>
                                <ondown>9102</ondown>
                                <onleft>9101</onleft>
                                <onright>9101</onright>
                                <scrolltime>200</scrolltime>
                                <orientation>horizontal</orientation>
                                <include>InfoList_OnBack</include>
                                <include content="InfoList_OnClick">
                                    <param name="prevent_del" value="noop" />
                                </include>
                                <include content="CastLayout">
                                    <param name="viewid">9101</param>
                                    <param name="belowdoublelabel1">$INFO[ListItem.Label] $INFO[ListItem.Year,(,)]</param>
                                    <param name="belowdoublelabel2">$INFO[ListItem.Property(character)]</param>
                                </include>
                                <content>
                                    <item>
                                        <icon>DefaultAddonNone.png</icon>
                                        <thumb>DefaultAddonNone.png</thumb>
                                        <visible>String.IsEmpty(Container(9101).ListItem(1).Label)</visible>
                                    </item>
                                </content>
                                <content sortby="year" sortorder="descending" limit="25" target="videos">$VAR[InfoCastList01]</content>                        
                            </control>
                        </control>
                    </control>
                    
                    <control type="group">
                        <height>450</height>
                        <control type="group">
                            <control type="label">
                                <left>8</left>
                                <top>0</top>
                                <height>30</height>
                                <label>Cast in TV Shows</label>
                            </control>
                            <control type="image" description="Line Split">
                                <top>38</top>
                                <left>10</left>
                                <width>1180</width>
                                <height>1</height>
                                <texture>img/LineL.png</texture>
                                <aspectratio>stretch</aspectratio>
                            </control>
                            <control type="list" id="9102">
                                <top>42</top>
                                <width>1180</width>
                                <height>410</height>
                                <onup>9101</onup>
                                <ondown>9103</ondown>
                                <onleft>9102</onleft>
                                <onright>9102</onright>
                                <scrolltime>200</scrolltime>
                                <orientation>horizontal</orientation>
                                <include>InfoList_OnBack</include>
                                <include content="InfoList_OnClick">
                                    <param name="prevent_del" value="noop" />
                                </include>
                                <include content="CastLayout">
                                    <param name="viewid">9102</param>
                                    <param name="belowdoublelabel1">$INFO[ListItem.Label] $INFO[ListItem.Year,(,)]</param>
                                    <param name="belowdoublelabel2">$INFO[ListItem.Property(character)]</param>
                                </include>
                                <content>
                                    <item>
                                        <icon>DefaultAddonNone.png</icon>
                                        <thumb>DefaultAddonNone.png</thumb>
                                        <visible>String.IsEmpty(Container(9102).ListItem(1).Label)</visible>
                                    </item>
                                </content>
                                <content sortby="year" sortorder="descending" limit="25" target="videos">$VAR[InfoCastList02]</content>                        
                            </control>
                        </control>
                    </control>

                    <control type="group">
                        <height>450</height>
                        <control type="group">
                            <control type="label">
                                <left>8</left>
                                <top>0</top>
                                <height>30</height>
                                <label>Crew in Movies</label>
                            </control>
                            <control type="image" description="Line Split">
                                <top>38</top>
                                <left>10</left>
                                <width>1180</width>
                                <height>1</height>
                                <texture>img/LineL.png</texture>
                                <aspectratio>stretch</aspectratio>
                            </control>
                            <control type="list" id="9103">
                                <top>42</top>
                                <width>1180</width>
                                <height>410</height>
                                <onup>9102</onup>
                                <ondown condition="Integer.IsGreater(Container(9104).NumItems,0)">9104</ondown>
                                <onleft>9103</onleft>
                                <onright>9103</onright>
                                <scrolltime>200</scrolltime>
                                <orientation>horizontal</orientation>
                                <include>InfoList_OnBack</include>
                                <include content="InfoList_OnClick">
                                    <param name="prevent_del" value="noop" />
                                </include>
                                <include content="CastLayout">
                                    <param name="viewid">9103</param>
                                    <param name="belowdoublelabel1">$INFO[ListItem.Label] $INFO[ListItem.Year,(,)]</param>
                                    <param name="belowdoublelabel2">$INFO[ListItem.Property(job)]</param>
                                </include>
                                <content>
                                    <item>
                                        <icon>DefaultAddonNone.png</icon>
                                        <thumb>DefaultAddonNone.png</thumb>
                                        <visible>String.IsEmpty(Container(9103).ListItem(1).Label)</visible>
                                    </item>
                                </content>
                                <content sortby="year" sortorder="descending" limit="25" target="videos">$VAR[InfoCastList03]</content>                        
                            </control>
                        </control>
                    </control>
                    
                   <control type="group">
                        <height>450</height>
                        <control type="group">
                            <control type="label">
                                <left>8</left>
                                <top>0</top>
                                <height>30</height>
                                <label>Crew in TV Shows</label>
                            </control>
                            <control type="image" description="Line Split">
                                <top>38</top>
                                <left>10</left>
                                <width>1180</width>
                                <height>1</height>
                                <texture>img/LineL.png</texture>
                                <aspectratio>stretch</aspectratio>
                            </control>
                            <control type="list" id="9104">
                                <top>42</top>
                                <width>1180</width>
                                <height>410</height>
                                <onup>9103</onup>
                                <onleft>9104</onleft>
                                <onright>9104</onright>
                                <scrolltime>200</scrolltime>
                                <orientation>horizontal</orientation>
                                <include>InfoList_OnBack</include>
                                <include content="InfoList_OnClick">
                                    <param name="prevent_del" value="noop" />
                                </include>
                                <include content="CastLayout">
                                    <param name="viewid">9104</param>
                                    <param name="belowdoublelabel1">$INFO[ListItem.Label] $INFO[ListItem.Year,(,)]</param>
                                    <param name="belowdoublelabel2">$INFO[ListItem.Property(job)]</param>
                                </include>
                                <content>
                                    <item>
                                        <icon>DefaultAddonNone.png</icon>
                                        <thumb>DefaultAddonNone.png</thumb>
                                        <visible>String.IsEmpty(Container(9104).ListItem(1).Label)</visible>
                                    </item>
                                </content>
                                <content sortby="year" sortorder="descending" limit="25" target="videos">$VAR[InfoCastList04]</content>                        
                            </control>
                        </control>
                    </control>
                    
                </control>   
            </control>

Is there a trick to making the visibility conditions work and only show the lists that have content? I know I have asked way too many questions already, so I understand if you don't have the time or inclination to look at this.

I do have a feature request: Could you please add properties to indicate for a person how many total movies and total tv shows were found in tmdb, and also how many are in the local database? This is something that Extendedinfo had that I am missing.  Thanks for considering this request.

Regards,

Bart
Reply


Messages In This Thread
RE: TheMovieDB Helper - by jurialmunkey - 2019-07-31, 11:47
RE: plugin.video.themoviedb.helper - Access to TheMovieDb API for Skinners - by bsoriano - 2019-08-24, 01:59
Logout Mark Read Team Forum Stats Members Help
plugin.video.themoviedb.helper - Access to TheMovieDb API for Skinners2