Example #1
0
        private async void OnPiryInstallComplete()
        {
            await Dispatcher.SwitchToUi();

            PirySetup.InstallComplete -= OnPiryInstallComplete;
            PirySetup.OnPiryOutput    -= HandlePiryOutput;

            Write(Properties.Resources.PiryInstall_BO2Downloaded);

            Window.EnableBackButton = false;

            var plutoniumConfigPage = new PlutoniumConfigPage
            {
                BO2Directory = BO2Directory
            };

            Window.Navigate(plutoniumConfigPage);
        }
        private void GoToPlutoniumSetup()
        {
            var bo2Directory = GetBO2InstalledDirectory();

            if (string.IsNullOrWhiteSpace(bo2Directory))
            {
                return;
            }

            if (IsMissingDLC(bo2Directory))
            {
                var result = System.Windows.MessageBox.Show(Properties.Resources.Start_DLCMissing,
                                                            Properties.Resources.Start_DLCMissingHeader,
                                                            MessageBoxButton.YesNoCancel,
                                                            MessageBoxImage.Question);

                if (result == MessageBoxResult.Yes)
                {
                    var piryInstallPage = new PiryInstallPage
                    {
                        BO2Directory = bo2Directory
                    };

                    Window.Navigate(piryInstallPage);
                    return;
                }
                else if (result == MessageBoxResult.Cancel)
                {
                    return;
                }
            }

            var plutoConfigPage = new PlutoniumConfigPage
            {
                BO2Directory = bo2Directory
            };

            Window.EnableBackButton = true;
            Window.Navigate(plutoConfigPage);
        }