public void PosterViewActive() { posterViewModel = new PosterViewModel(); posterViewModel.LoadGames(); posterViewModel.LoadGenres(); DataContext = posterViewModel; }
public MainWindow() { LoadAllGames lag = new LoadAllGames(); LoadSettings(); MakeDirectories(); MakeDefaultGenres(); lag.LoadGenres(); DeleteWorkingDirContents(); InitializeComponent(); posterViewModel = new PosterViewModel(); posterViewModel.LoadGames(); posterViewModel.LoadGenres(); DataContext = posterViewModel; }
public void LagBWRunWorkerCompleted(object sender, RunWorkerCompletedEventArgs e) { GameListMW = lag.Games; GenreListMW = lag.Genres; posterViewModel.LoadGames(); listViewModel.LoadGames(); bannerViewModel.LoadGames(); if (Settings.Default.viewtype.ToString() == "Poster") { PosterViewActive(); } if (Settings.Default.viewtype.ToString() == "Banner") { BannerViewActive(); } if (Settings.Default.viewtype.ToString() == "List") { ListViewActive(); } DialogFrame.Visibility = Visibility.Hidden; }