Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix Episode Thumb #116

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

cinqmilleans
Copy link

This pr fixes a bug. Thumbnails of unwatched episodes are always displayed, instead of fanart when the corresponding kodi option is selected. This seems to be a kodi bug but here is a fix.

Issue kodi: xbmc/xbmc#21656.

@jurialmunkey
Copy link
Owner

ListItem.Thumb is depreciated (as you note in your bug report) so it shouldn't be used (it is an alias for ListItem.Icon here).

You can check that spoiler isn't being hidden before displaying thumb using this condition:
String.IsEqual(ListItem.DBType,episode) + !String.IsEmpty(ListItem.Art(thumb)) + !String.IsEqual(ListItem.Icon,ListItem.Art(fanart)) + !String.IsEqual(ListItem.Icon,OverlaySpoiler.png)

e.g.

<value condition="String.IsEqual(ListItem.DBType,episode) + !String.IsEmpty(ListItem.Art(thumb)) + !String.IsEqual(ListItem.Icon,ListItem.Art(fanart)) + !String.IsEqual(ListItem.Icon,OverlaySpoiler.png)">$INFO[ListItem.Art(thumb)]</value>
<value condition="String.IsEqual(ListItem.DBType,episode)">$INFO[ListItem.Icon]</value>

@cinqmilleans
Copy link
Author

I modified the code. Currently it shows tvshow.fanart if available or black if not. It can be modified later to handle more cases.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants