private void Button_Click(object sender, RoutedEventArgs e) { TweetScanHelper ts = new TweetScanHelper(); TweetCollection searchREsults = ts.GetSearchResults(SearchTextBox.Text); foreach (Tweet t in searchREsults) { tweets.Add(t); } }
private void TweetScanButton_Click(object sender, RoutedEventArgs e) { TweetScanHelper ts = new TweetScanHelper(); TweetCollection searchResults = ts.GetSearchResults(FilterTextBox.Text); // TODO: this should be displayed somewhere else instead of the main tweets listbox. for (int i = searchResults.Count - 1; i >= 0; i--) { Tweet tweet = searchResults[i]; if (!tweets.Contains(tweet)) { tweets.Insert(0, tweet); tweet.Index = tweets.Count; tweet.IsNew = true; tweet.IsSearchResult = true; } } }