private void addCommonPicturesToListBox()
        {
            User selectedFriend          = listBoxFriends.SelectedItem as User;
            LinkedList <Photo> photoList = CommonPhotosLogic.MakeListOfCommonPhotos(LogicApp.UserAlbumsCollection, selectedFriend.Name);

            foreach (Photo currentPhoto in photoList)
            {
                listBoxCommonPhoto.Items.Add(currentPhoto);
            }
        }
示例#2
0
        public List <string> getCommonPhotoNameList(string friendName)
        {
            List <string> commonPhotoNameList = new List <string>();

            currentSelectedFriendName    = friendName;
            currentCommonPhotoLinkedList = CommonPhotosLogic.MakeListOfCommonPhotos(UserAlbumsCollection, friendName);
            foreach (Photo currentPhoto in currentCommonPhotoLinkedList)
            {
                commonPhotoNameList.Add(currentPhoto.CreatedTime.ToString());
            }

            return(commonPhotoNameList);
        }
示例#3
0
        public List <string> getSortedCommonPhotoNameList(string friendName, int sortType)
        {
            CreateConcretePopularCriteria(sortType);

            List <string> commonPhotoNameList = new List <string>();

            currentSelectedFriendName    = friendName;
            currentCommonPhotoLinkedList = CommonPhotosLogic.MakeListOfCommonPhotos(UserAlbumsCollection, friendName);

            List <Photo> currentCommonPhotoList = currentCommonPhotoLinkedList.ToList();

            ListPhotoBubbleSort(currentCommonPhotoList);

            foreach (Photo currentPhoto in currentCommonPhotoList)
            {
                String photoName = String.Format("{0}", currentPhoto.CreatedTime.ToString());
                commonPhotoNameList.Add(photoName);
            }

            return(commonPhotoNameList);
        }