private void TwitterSearch() { using (SearchForm f = new SearchForm()) { this.statList.Visible = false; IsLoaded = false; SavedSearchTimeLine SavedSearch; // setting this is the right thing to do, but kills the // combobox - the drop-down list gets hidden behind the form // WEIRD. //f.Owner = this; if (f.ShowDialog() == DialogResult.Cancel) { IsLoaded = true; this.statList.Visible = true; f.Dispose(); return; } IsLoaded = true; this.statList.Visible = true; f.Hide(); string SearchString = f.SearchText; SavedSearch = f.SavedSearch; if(SavedSearch!=null) { AddGroupSelectMenuItem(SavedSearch); } f.Dispose(); statList.Visible = true; ShowSearchResults(SearchString, (SavedSearch!=null && SavedSearch.autoUpdate)); } }
private void TwitterSearch() { using (SearchForm f = new SearchForm()) { this.statList.Visible = false; IsLoaded = false; if (f.ShowDialog() == DialogResult.Cancel) { IsLoaded = true; this.statList.Visible = true; f.Close(); return; } IsLoaded = true; this.statList.Visible = true; f.Hide(); string SearchString = f.SearchText; f.Close(); this.statList.Visible = true; ShowSearchResults(SearchString); } }
private void TwitterSearch() { using (SearchForm f = new SearchForm()) { this.statList.Visible = false; IsLoaded = false; SavedSearchTimeLine SavedSearch; if (f.ShowDialog() == DialogResult.Cancel) { IsLoaded = true; this.statList.Visible = true; f.Close(); return; } IsLoaded = true; this.statList.Visible = true; f.Hide(); string SearchString = f.SearchText; SavedSearch = f.SavedSearch; if(SavedSearch!=null) { AddGroupSelectMenuItem(SavedSearch); } f.Close(); statList.Visible = true; ShowSearchResults(SearchString, (SavedSearch!=null && SavedSearch.autoUpdate)); } }
private void MapList() { Cursor.Current = Cursors.WaitCursor; Application.DoEvents(); using (ProfileMap m = new ProfileMap()) { List<Library.User> users = new List<Library.User>(); for (int i = 0; i < statList.m_items.Count; i++) { Library.User thisUser = statList.m_items[i].Tweet.user; if (thisUser.needsFetching) { thisUser = Library.User.FromId(thisUser.screen_name, statList.m_items[i].Tweet.Account); thisUser.needsFetching = false; } users.Add(thisUser); } m.Users = users; m.ShowDialog(); if (m.Range > 0) { SearchForm f = new SearchForm(); f.providedDistnce = m.Range.ToString(); string secondLoc = Yedda.GoogleGeocoder.Geocode.GetAddress(m.CenterLocation.ToString()); if (string.IsNullOrEmpty(secondLoc)) { secondLoc = m.CenterLocation.ToString(); } f.providedLocation = secondLoc; this.statList.Visible = false; IsLoaded = false; if (f.ShowDialog() == DialogResult.Cancel) { IsLoaded = true; this.statList.Visible = true; f.Close(); return; } IsLoaded = true; this.statList.Visible = true; f.Hide(); string SearchString = f.SearchText; f.Close(); this.statList.Visible = true; ShowSearchResults(SearchString); } m.Close(); } }