00001 #ifndef VIDEOLIST_H_ 00002 #define VIDEOLIST_H_ 00003 00004 // Type of the item added to the tree 00005 enum TreeNodeType { 00006 kSubFolder = -1, 00007 kUpFolder = -2, 00008 kRootNode = -3 00009 }; 00010 00011 // Tree node attribute index 00012 enum TreeNodeAttributes { 00013 kNodeSort, 00014 kFolderPath 00015 }; 00016 00017 class GenericTree; 00018 class VideoFilterSettings; 00019 class Metadata; 00020 class MetadataListManager; 00021 class ParentalLevel; 00022 00023 class VideoList 00024 { 00025 public: 00026 VideoList(); 00027 ~VideoList(); 00028 00029 GenericTree *buildVideoList(bool filebrowser, bool flatlist, 00030 const ParentalLevel &parental_level, 00031 bool include_updirs); 00032 00033 void refreshList(bool filebrowser, const ParentalLevel &parental_level, 00034 bool flatlist); 00035 00036 // If the only change to the underlying metadata requires 00037 // another sort (for video manager currently). 00038 void resortList(bool flat_list); 00039 00040 Metadata *getVideoListMetadata(int index); 00041 const Metadata *getVideoListMetadata(int index) const; 00042 unsigned int count() const; 00043 00044 const VideoFilterSettings &getCurrentVideoFilter(); 00045 void setCurrentVideoFilter(const VideoFilterSettings &filter); 00046 00047 // returns the number of videos matched by this filter 00048 int test_filter(const VideoFilterSettings &filter) const; 00049 00050 unsigned int getFilterChangedState(); 00051 00052 bool Delete(int video_id); 00053 00054 const MetadataListManager &getListCache() const; 00055 00056 // returns the folder path associated with a returned tree 00057 QString getFolderPath(int folder_id) const; 00058 00059 private: 00060 class VideoListImp *m_imp; 00061 }; 00062 00063 #endif // VIDEOLIST_H
1.5.5