Example #1
0
        private void displayPostInformation()
        {
            PostWrapper postWrapperSelected = listBoxResult.SelectedItem as PostWrapper;

            displayPostInfo(postWrapperSelected);
            displayPostPicture(postWrapperSelected.Post);
        }
        private void refreshForm()
        {
            lock (m_lockShown)
            {
                if (m_IsInShown == false)
                {
                    clearListAsynchronous(listBoxPosts);
                    LoginForm.s_LoggedInUser.ReFetch();
                }
            }

            foreach (Post post in LoginForm.s_LoggedInUser.Posts)
            {
                PostWrapper postw = new PostWrapper(post);
                addObjectToListBoxAsynchronous(listBoxPosts, postw);
            }

            lock (m_lockShown)
            {
                if (m_IsInShown == false)
                {
                    m_IsInShown = true;
                }
            }
        }
Example #3
0
        private void displayPostInfo(PostWrapper i_Pw)
        {
            Post postToDisplay = i_Pw.Post;

            textBoxResultInfo.Invoke(new Action(() =>
            {
                textBoxResultInfo.Enabled = true;
            }));
            string message    = postToDisplay.Message == null ? string.Empty : postToDisplay.Message;
            string resultInfo = string.Format(
                @"{0}
{1}
Likes: {2}
Comments: {3}
Score: {4}",
                message,
                postToDisplay.CreatedTime.GetValueOrDefault(),
                postToDisplay.LikedBy.Count,
                postToDisplay.Comments.Count,
                getPostScore(postToDisplay));

            textBoxResultInfo.Text = resultInfo;
        }
Example #4
0
        public override string ToString()
        {
            PostWrapper handledPostWrapper = new PostWrapper(HandledPost);

            return(string.Format("{0} at {1} Likes {2} {3} Comments : {4}", IsUnlike ? "Unlike" : "Like", m_NumOfRequiredLikes, m_IsAndOperation ? "AND" : "OR", m_NumOfRequiredComments, handledPostWrapper));
        }
Example #5
0
        public override string ToString()
        {
            PostWrapper handledPostWrapper = new PostWrapper(HandledPost);

            return(string.Format("{0} at {1} : {2}", IsUnlike ? "Unlike" : "Like", m_Schedule.DesiredDateTime, handledPostWrapper));
        }
Example #6
0
        public override string ToString()
        {
            PostWrapper handledPostWrapper = new PostWrapper(HandledPost);

            return(string.Format("Comment at {0} Likes {1} {2} Comments : {3}", m_NumOfRequiredLikes, m_IsAndOperation ? "AND" : "OR", m_NumOfRequiredComments, handledPostWrapper));
        }
        public override string ToString()
        {
            PostWrapper handledPostWrapper = new PostWrapper(HandledPost);

            return(string.Format("Comment at {0} : {1}", m_Schedule.DesiredDateTime, handledPostWrapper));
        }