コード例 #1
0
        public void FirstTimeSetup(Mutex m, Service_JsonParser jsp,
                                   NamedPipeManager npm, List <DatabaseContext_Profile> profiles, ProfilesManager profileManager)
        {
            if (GetCollection <Game>("games").Count() > 0)
            {
                GetCollection <Game>("games").Delete(x => true);
            }

            if (GetCollection <GameApplication>("game_apps").Count() > 0)
            {
                GetCollection <GameApplication>("game_apps").Delete(x => true);
            }
            foreach (var item in profiles)
            {
                item.Dispose();
            }
            profiles.Clear();

            foreach (var item in GetCollection <UserProfile>("profiles").FindAll())
            {
                profileManager.DeleteProfile(item.ProfileId);
            }

            AvailableGamesWindow chooseGames = new AvailableGamesWindow(m, this, jsp, npm, profiles, profileManager);

            chooseGames.Show();
        }
コード例 #2
0
 void ConfigureAdditionalGames()
 {
     gamePicker.Dispatcher.BeginInvoke((Action)(() =>
     {
         AvailableGamesWindow gameDetectWindow = new AvailableGamesWindow(_db, uponConfigured: InitGamePicker);
         gameDetectWindow.Show();
     }));
 }