private void ResponseUSTweet(ClientTweet tweet) { tweet.Init(); if (tweet.isRetweet && DataInstence.CheckIsMe(tweet.user.id)) { tweet.originalTweet.retweeted = true; } TweetInstence.AddTweet(eTweetPanel.eHome, tweet); //DeleAddTweet dele = new DeleAddTweet(TweetInstence.AddTweet); //Application.Current.Dispatcher.BeginInvoke(dele, new object[] { eTweetPanel.eHome, tweet }); }
//스트리밍에서 호출하게 될 트윗 추가 public void AddTweet(eTweetPanel panel, ClientTweet tweet) { lock (lockObject) { tweet.Init(); //if (DataInstence.CheckIsMe(tweet.user.id))//내트윗일 경우 작업 //{ // DataInstence.UpdateMyScreenName(tweet.user.screen_name);//아이디 변경 체크 // DataInstence.UpdateMyProfilePicture(tweet.user.profile_image_url);//인장 변경 체크 //} if (dicHashs[panel].Contains(tweet.id)) { return; //중복 트윗 } if (DataInstence.isShowTweet(tweet, panel) == false) { return; //트윗 미표시 } bool isShowTweet = true; if (panel == eTweetPanel.eHome) { if (DataInstence.option.MatchHighlight(tweet.originalTweet.text) || tweet.isMention) //하이라이트,멘션 멘션에 추가 { AddTweetData(eTweetPanel.eMention, tweet); } else if (DataInstence.CheckIsMe(tweet.originalTweet.user.id) && tweet.retweeted) //내 트윗 체크(리트윗용) { isShowTweet = DataInstence.option.isShowRetweet; //리트윗을 TL표시할경우 추가 if (isShowTweet && DataInstence.option.isNotiRetweet) //리트윗 멘션함에 오게 할 경우 추가 { AddTweetData(eTweetPanel.eMention, tweet); } //if (DataInstence.CheckIsMe(tweet.user.id) && tweet.retweeted_status != null)//내가 한 리트윗 // Retweet(tweet, true); } } if (isShowTweet) { AddTweetData(panel, tweet); } //if (DataInstence.CheckIsMe(tweet.user.id) && tweet.retweeted_status != null)//리트윗 갱신 // Retweet(tweet, true); } }
private void LoadDeahwaThread(object obj) { ClientTweet tweet = obj as ClientTweet; if (tweet == null) { return; } PacketSingleTweet parameter = new PacketSingleTweet(tweet.originalTweet.in_reply_to_status_id_str); string json = WebInstence.SyncRequest(parameter); ClientTweet dhTweet = JsonConvert.DeserializeObject <ClientTweet>(json); if (dhTweet == null) { DalsaeInstence.ShowMessageBox("이전 대화 유저가 잠금 계정 혹은 차단된 상태입니다.", "오류"); } else { dhTweet.Init(); UIProperty.DeleAddSingleTweet dele = new UIProperty.DeleAddSingleTweet(tweet.uiProperty.AddSingleTweet); Application.Current.Dispatcher.BeginInvoke (dele, new object[] { dhTweet, tweet.uiProperty.isQtTweet ? tweet.uiProperty : tweet.uiProperty.parentTweet, false }); } }
private void ResponseUnFavorite(ClientTweet tweet) { tweet.Init(); TweetInstence.FavoriteTweet(tweet, tweet.favorited); }
private void ResponseUnRetweet(ClientTweet tweet) { tweet.Init(); TweetInstence.Retweet(tweet, false); }
private void ResponseRetweet(ClientTweet tweet) { tweet.Init(); TweetInstence.Retweet(tweet, true); }