コード例 #1
0
 //Syncs Manifest With Launcher
 private void resyncManifest()
 {
     if ((ResyncButton.ButtonOn) && (SwitcherCheck.SyncError))
     {
         SwitcherCore.switchInstall_Epic("switchToClean");
         MessageBox.Show("Manifest Synced, Please restart switcher for changes to take effect.", "Success!");
     }
 }
コード例 #2
0
        private void InstallSwitch_MouseLeftButtonDown(object sender, MouseButtonEventArgs e)
        {
            //Checks InstallSwitch Status After Each Click And Execeutes Actions Accordingly
            if (SwitcherCore.LauncherSelect == "EpicGames")
            {
                if ((!SwitcherCheck.SyncError))
                {
                    if (!InstallSwitch.SwitchOn)
                    {
                        textInstallStatus.Text        = textUnmodded;
                        textInstallStatus.Foreground  = textColorUnmodded;
                        InstallStatusContainer.Stroke = textColorUnmodded;

                        SwitcherCore.switchInstall_Epic("switchToClean");
                    }
                    else
                    {
                        textInstallStatus.Text        = textModded;
                        textInstallStatus.Foreground  = textColorModded;
                        InstallStatusContainer.Stroke = textColorModded;

                        SwitcherCore.switchInstall_Epic("switchToModded");
                    }
                }
                else
                {
                    MessageBox.Show("Manifest and Launcher not synced!", "Something Went Wrong");
                }
            }
            else if (SwitcherCore.LauncherSelect == "Steam")
            {
                if (!InstallSwitch.SwitchOn)
                {
                    textInstallStatus.Text        = textUnmodded;
                    textInstallStatus.Foreground  = textColorUnmodded;
                    InstallStatusContainer.Stroke = textColorUnmodded;
                }
                else
                {
                    textInstallStatus.Text        = textModded;
                    textInstallStatus.Foreground  = textColorModded;
                    InstallStatusContainer.Stroke = textColorModded;
                }
            }
        }