コード例 #1
0
        private void btnBrowseRootDir_Click(object sender, EventArgs e)
        {
            string oldRootDir = txtRootFolder.Text;
            string dirNew     = Adapter.GetDirPathUsingFolderBrowser("Configure Root directory...");

            if (!string.IsNullOrEmpty(dirNew))
            {
                Engine.SetRootFolder(dirNew);
                txtRootFolder.Text = Engine.ConfigApp.RootDir;
                FileSystem.MoveDirectory(oldRootDir, txtRootFolder.Text);
                ConfigurePaths();
                Engine.ConfigUI = XMLSettings.Read();
                Loader.MainForm.ZScreen_ConfigGUI();
            }
        }
コード例 #2
0
        private void AppSettingsImport()
        {
            OpenFileDialog dlg = new OpenFileDialog
            {
                Filter           = FILTER_XML_FILES,
                InitialDirectory = Environment.GetFolderPath(Environment.SpecialFolder.MyDocuments)
            };

            if (dlg.ShowDialog() == DialogResult.OK)
            {
                XMLSettings temp = XMLSettings.Read(dlg.FileName);
                temp.FirstRun   = false;
                Engine.ConfigUI = temp;
                Loader.MainForm.ZScreen_ConfigGUI();
            }
        }
コード例 #3
0
ファイル: Program.cs プロジェクト: OriginalCliff/itsfv
 static void SettingsReader_DoWork(object sender, DoWorkEventArgs e)
 {
     Program.Config = XMLSettings.Read(ConfigCoreFilePath);
 }