Kodi Community Forum
ListItem.Date confusion - Printable Version

+- Kodi Community Forum (https://forum.kodi.tv)
+-- Forum: Development (https://forum.kodi.tv/forumdisplay.php?fid=32)
+--- Forum: Skinning (https://forum.kodi.tv/forumdisplay.php?fid=12)
+--- Thread: ListItem.Date confusion (/showthread.php?tid=130842)



ListItem.Date confusion - Hitcher - 2012-05-06

There are 2 entries in the wiki for ListItem.Date and neither seem to return the correct info.

ListItem.Date
  • Shows the file date of the currently selected song or movie in a list or thumb control
  • Day, start time and end time of current selected TV programme in a list or thumb control

Actual results

Movies - empty
TV Shows - same date as ListItem.Premiered
Episodes - same date as ListItem.Premiered
Songs - empty


RE: ListItem.Date confusion - Jezz_X - 2012-05-06

I'm not sure about shows but episodes would be the same because you probably get the episodes the same day they aired like I said in the other thread about it


RE: ListItem.Date confusion - Hitcher - 2012-05-06

Unfortunately not.


RE: ListItem.Date confusion - jmarshall - 2012-05-06

From the code:

ListItem.Date returns the m_dateTime object of a filetime.

For files this is the creation or modified date (might depend on the filesystem).

For library items, we typically don't have this value, so we set the value to dates we do have:

Shows: Premiered
Episodes: First Aired

Every other library item (albums, songs, artists, genres, movies, musicvids etc. etc.) will have no info available. So this gels with what you see. Whether it's sane or not I dunno Smile

Cheers,
Jonathan


RE: ListItem.Date confusion - Hitcher - 2012-05-07

Thanks Jonathan.

So where does this wiki entry come from?

ListItem.Date - Day, start time and end time of current selected TV programme in a list or thumb control


ListItem.Date confusion - pecinko - 2012-05-07

Well, in that case it's a pitty that years are not set to it for other library items as we could have universal tag - file dates for files and relevant info for library items. Video addons could use it for date published/aired.


RE: ListItem.Date confusion - jmarshall - 2012-05-07

@Hitcher: My guess is it's being used for the tvguide stuff perhaps (PVR)? No idea otherwise Smile

@pecinko: I don't mind a universal tag, but I prefer specific ones are available as well in cases where more than one date might be available for the item. Not sure if this applies here though!


RE: ListItem.Date confusion - Jezz_X - 2012-05-07

(2012-05-07, 00:45)jmarshall Wrote: @Hitcher: My guess is it's being used for the tvguide stuff perhaps (PVR)? No idea otherwise Smile

you are absolutely right about that now that you mention it that data is what shows in the PVR windows for its items