public void importThread(List <ForumPost> posts, long threadID) { if (posts != null) { if (this.threadArray[threadID] == null) { ForumThreadInfoData data = new ForumThreadInfoData { threadID = threadID }; this.threadArray[threadID] = data; } ForumThreadInfoData data2 = (ForumThreadInfoData)this.threadArray[threadID]; data2.forumPosts = new List <ForumPostData>(); foreach (ForumPost post in posts) { ForumPostData item = new ForumPostData { text = post.postText, postID = post.postID, postTime = post.date, userName = post.userName, userID = post.userID }; if (item.postTime > data2.lastTime) { data2.lastTime = item.postTime; } data2.forumPosts.Add(item); } this.addPosts(); } }
public void importThread(List<ForumPost> posts, long threadID) { if (posts != null) { if (this.threadArray[threadID] == null) { ForumThreadInfoData data = new ForumThreadInfoData { threadID = threadID }; this.threadArray[threadID] = data; } ForumThreadInfoData data2 = (ForumThreadInfoData) this.threadArray[threadID]; data2.forumPosts = new List<ForumPostData>(); foreach (ForumPost post in posts) { ForumPostData item = new ForumPostData { text = post.postText, postID = post.postID, postTime = post.date, userName = post.userName, userID = post.userID }; if (item.postTime > data2.lastTime) { data2.lastTime = item.postTime; } data2.forumPosts.Add(item); } this.addPosts(); } }
public void ForumPostNotif(ForumPostData post) { QueueNotif(ForumApp.Icon, "New Ruddit post!", ForumApp); }