Esempio n. 1
0
        private void OpenSteamAccount(SteamAccount steamAccount)
        {
            string saveDataPath = Path.Combine(SteamUtility.GetMhwSaveDir(steamAccount) !, "SAVEDATA1000");

            MainWindowViewModel.Instance.SetActiveViewModel(new SaveDataViewModel(saveDataPath)
            {
                SteamAccount = steamAccount
            });
        }
Esempio n. 2
0
        private async Task ShowOpenFileDialog()
        {
            OpenFileDialog ofd = new OpenFileDialog {
                AllowMultiple = false
            };

            string?initialPath = SteamUtility.GetMhwSaveDir();

            if (initialPath != null)
            {
                ofd.Directory = initialPath;
            }

            var filePath = (await ofd.ShowAsync()).FirstOrDefault();

            if (filePath == null)
            {
                CtxLog.Information("No file selected");
            }
            else
            {
                MainWindowViewModel.Instance.SetActiveViewModel(new SaveDataViewModel(filePath));
            }
        }