void CPlayCenter::GetAllPlayList() { RemoveAllList(); if (theRuntimeState->GetLogUserInfo()) { theDbMgr->SetCurrentUser(theRuntimeState->GetLogUserInfo()); } { std::vector<spPlayListInfoT> PlayList; theDbMgr->GetUserDB()->GetAllPlayLists(PlayList); for (auto it=PlayList.begin();it!=PlayList.end();++it) { CPlayListInfo playList; playList.SetComment((*it)->GetComment()); playList.SetFlag((*it)->GetFlag()); playList.SetId((*it)->GetId()); playList.SetListType((*it)->GetListType()); playList.SetLocalId((*it)->GetLocalId()); playList.SetName((*it)->GetName()); playList.SetShow((*it)->IsShow()); playList.SetTag((*it)->GetTag()); AddPlayList(playList); std::vector<spSongInfoT> SongList; theDbMgr->GetUserDB()->GetPlayListSongs(SongList,(*it)->GetLocalId()); for (auto it2=SongList.begin();it2!=SongList.end();++it2) { CSongInfo songInfo; songInfo.SetAblumName((*it2)->GetAlbumName()); songInfo.SetAddTime((*it2)->GetAddTime()); songInfo.SetAlbumId((*it2)->GetAlbumId()); songInfo.SetArtistId((*it2)->GetArtistId()); songInfo.SetArtistName((*it2)->GetArtistName()); songInfo.SetAudioLength((*it2)->GetAudioLength()); songInfo.SetCoverLocalPath((*it2)->GetCoverLocalPath()); songInfo.SetCoverUrl((*it2)->GetCoverUrl()); songInfo.SetEnable((*it2)->IsEnable()); songInfo.SetFileExt((*it2)->GetFileExt()); songInfo.SetFileSize((*it2)->GetFileSize()); songInfo.SetFileStartPos((*it2)->GetFileStartPos()); songInfo.SetFileType((*it2)->GetFileType()); songInfo.SetFlag((*it2)->GetFlag()); songInfo.SetLastModifyTime((*it2)->GetLastModifyTime()); songInfo.SetLastPlayTime((*it2)->GetLastPlayTime()); songInfo.SetListenFileUrl((*it2)->GetListenFileUrl()); songInfo.SetLocal((*it2)->IsLocal()); songInfo.SetLocalId((*it2)->GetLocalId()); songInfo.SetLocalPath((*it2)->GetLocalPath()); songInfo.SetLrcLocalPath((*it2)->GetLrcLocalPath()); songInfo.SetLrcUrl((*it2)->GetLrcUrl()); songInfo.SetMD5((*it2)->GetMD5()); songInfo.SetPlayCount((*it2)->GetPlayCount()); songInfo.SetRealArtistName((*it2)->GetRealArtistName()); songInfo.SetResourceID((*it2)->GetResourceId()); songInfo.SetSongId((*it2)->GetSongId()); songInfo.SetSongName((*it2)->GetSongName()); songInfo.SetTag((*it2)->GetTag()); AddSongToList(songInfo,(*it)->GetLocalId()); } } } }