示例#1
0
        /// <summary>
        /// Function called when you want to modify game paths of a platform
        /// </summary>
        /// <param name="platSel"></param>
        private void Change_Platform_Games_Paths(string platSel)
        {
            Debug.WriteLine($"Change Platform Games Paths - Selected Platform: {platSel}");
            CGamesPaths tcpj = new CGamesPaths();

            tcpj.Initialization(dicPlatforms[platSel]);
            tcpj.ShowDialog();
        }
        private void ApplyChanges()
        {
            boxLog.Text += @"Process start ..." + Environment.NewLine;

            //
            Properties.Settings.Default.CheatCodesFolder = tbCCodes.Text;
            Properties.Settings.Default.AppFolder        = this.tbGames.Text;
            Properties.Settings.Default.ImagesFolder     = this.tbImages.Text;
            Properties.Settings.Default.ManualFolder     = this.tbManual.Text;
            Properties.Settings.Default.MusicFolder      = this.tbMusic.Text;
            Properties.Settings.Default.VideoFolder      = this.tbVideo.Text;
            Properties.Settings.Default.Save();

            DematrioChka();

            if (!DebugMode)
            {
                _PlatformObject.Folder = _AMVFolders[0].FolderPath;

                PluginHelper.DataManager.Save();
            }


            PlatformFolder = _AMVFolders[0].FolderPath;

            FillInformation();
            GenerateInfoPath(_AMVFolders);

            var res = MessageBox.Show($"{Lang.Save_Ok}\n{Lang.Games_Paths_Question}", Lang.Save_Title, MessageBoxButtons.YesNo, MessageBoxIcon.Information);

            if (res == DialogResult.Yes)
            {
                CGamesPaths tcpj = new CGamesPaths();
                tcpj.Initialization(_PlatformObject);
                this.Hide();
                tcpj.ShowDialog();
                this.Close();
            }
            else
            {
                //FillInformation();
                btApply.Visible = false;
                btSimul.Visible = true;
            }
            //MessageBox.Show(Lang.Save_Ok, Lang.Save_Title, MessageBoxButtons.OK, MessageBoxIcon.Information);
        }