Esempio n. 1
0
        private async void LaunchApplication_PreviewMouseDown(object sender, MouseButtonEventArgs e)
        {
            if (e.LeftButton == MouseButtonState.Pressed)
            {
                ViewModel.CheckModCompatibility();
                await Setup.CheckForMissingDependencies();

                var appConfig = ViewModel.ApplicationTuple.Config;
                var launcher  = ApplicationLauncher.FromApplicationConfig(appConfig);
                launcher.Start();
            }
        }
Esempio n. 2
0
        private async void LaunchApplication_PreviewMouseDown(object sender, MouseButtonEventArgs e)
        {
            if (e.LeftButton == MouseButtonState.Pressed)
            {
                ViewModel.ApplicationTuple.Save();
                ViewModel.CheckModCompatibility();
                await Setup.CheckForMissingModDependenciesAsync();

                var appConfig = ViewModel.ApplicationTuple.Config;
                var launcher  = ApplicationLauncher.FromApplicationConfig(appConfig);

                if (!Environment.IsWine || (Environment.IsWine && CompatibilityDialogs.WineShowLaunchDialog()))
                {
                    launcher.Start();
                }
            }
        }