const CFileItem& operator=(const CFileItem& item);
virtual void Archive(CArchive& ar);
virtual void Serialize(CVariant& value) const;
- virtual void ToSortable(SortItem &sortable);
+ virtual void ToSortable(SortItem &sortable, Field field) const;
+ void ToSortable(SortItem &sortable, const Fields &fields) const;
virtual bool IsFileItem() const { return true; };
bool Exists(bool bUseCache = true) const;
/*!
+ \brief Check whether an item is an optical media folder or its parent.
+ This will return the non-empty path to the playable entry point of the media
+ one or two levels down (VIDEO_TS.IFO for DVDs or index.bdmv for BDs).
+ The returned path will be empty if folder does not meet this criterion.
+ \return non-empty string if item is optical media folder, empty otherwise.
+ */
+ std::string GetOpticalMediaPath() const;
+ /*!
\brief Check whether an item is a video item. Note that this returns true for
anything with a video info tag, so that may include eg. folders.
\return true if item is video, false otherwise.
bool IsInternetStream(const bool bStrictCheck = false) const;
bool IsPlayList() const;
bool IsSmartPlayList() const;
+ bool IsLibraryFolder() const;
bool IsPythonScript() const;
bool IsPlugin() const;
bool IsScript() const;
return m_pvrTimerInfoTag;
}
+ /*!
+ \brief Test if this item has a valid resume point set.
+ \return True if this item has a resume point and it is set, false otherwise.
+ */
+ bool IsResumePointSet() const;
+
+ /*!
+ \brief Return the current resume time.
+ \return The time in seconds from the start to resume playing from.
+ */
+ double GetCurrentResumeTime() const;
+
inline bool HasPictureInfoTag() const
{
return m_pictureInfoTag != NULL;
*/
CStdString FindLocalArt(const std::string &artFile, bool useFolder) const;
+ /*! \brief Whether or not to skip searching for local art.
+ \return true if local art should be skipped for this item, false otherwise.
+ \sa GetLocalArt, FindLocalArt
+ */
+ bool SkipLocalArt() const;
+
// Gets the .tbn file associated with this item
CStdString GetTBNFile() const;
// Gets the folder image associated with this item (defaults to folder.jpg)
void Assign(const CFileItemList& itemlist, bool append = false);
bool Copy (const CFileItemList& item, bool copyItems = true);
void Reserve(int iCount);
- void Sort(SORT_METHOD sortMethod, SortOrder sortOrder);
+ void Sort(SortBy sortBy, SortOrder sortOrder, SortAttribute sortAttributes = SortAttributeNone);
/* \brief Sorts the items based on the given sorting options
In contrast to Sort (see above) this does not change the internal
*/
void Stack(bool stackFiles = true);
- SortOrder GetSortOrder() const { return m_sortOrder; }
- SORT_METHOD GetSortMethod() const { return m_sortMethod; }
+ SortOrder GetSortOrder() const { return m_sortDescription.sortOrder; }
+ SortBy GetSortMethod() const { return m_sortDescription.sortBy; }
/*! \brief load a CFileItemList out of the cache
The file list may be cached based on which window we're viewing in, as different
*/
bool UpdateItem(const CFileItem *item);
- void AddSortMethod(SORT_METHOD method, int buttonLabel, const LABEL_MASKS &labelMasks);
+ void AddSortMethod(SortBy sortBy, int buttonLabel, const LABEL_MASKS &labelMasks, SortAttribute sortAttributes = SortAttributeNone);
+ void AddSortMethod(SortBy sortBy, SortAttribute sortAttributes, int buttonLabel, const LABEL_MASKS &labelMasks);
+ void AddSortMethod(SortDescription sortDescription, int buttonLabel, const LABEL_MASKS &labelMasks);
bool HasSortDetails() const { return m_sortDetails.size() != 0; };
const std::vector<SORT_METHOD_DETAILS> &GetSortDetails() const { return m_sortDetails; };
VECFILEITEMS m_items;
MAPFILEITEMS m_map;
bool m_fastLookup;
- SORT_METHOD m_sortMethod;
- SortOrder m_sortOrder;
+ SortDescription m_sortDescription;
bool m_sortIgnoreFolders;
CACHE_TYPE m_cacheToDisc;
bool m_replaceListing;