private void loadArtists() { List <string> loadedArtists = new List <string>(); loadedArtists = DatabaserSeeker.GetArtists("database.db", "music"); if (!Dispatcher.CheckAccess()) { Dispatcher.Invoke(() => artist_listView.ItemsSource = loadedArtists); return; } else { artist_listView.ItemsSource = loadedArtists; } }
private void loadGenre() { List <string> loadedGenre = new List <string>(); loadedGenre = DatabaserSeeker.GetGenres("database.db", "music"); if (!Dispatcher.CheckAccess()) { Dispatcher.Invoke(() => genre_list.ItemsSource = loadedGenre); return; } else { genre_list.ItemsSource = loadedGenre; } }
private void search_Button_Click(object sender, RoutedEventArgs e) { //searchEntry_TextBox.Items.Clear(); searchEntry_TextBox.ItemsSource = DatabaserSeeker.TitleSearch("database.db", "music", searchEntry_TextBox.Text); searchEntry_TextBox.IsDropDownOpen = true; }