Пример #1
0
        public Form1()
        {
            InitializeComponent();

            targetMcVersionBox.SelectedIndex = 0;

            foreach (string datafile in Directory.EnumerateFiles(Program.Initializer.DefaultDataDirPath))
            {
                this.dataFilesViewData.AddDataFile(datafile);
            }
            this.dataFilesLabel.Text = this.dataFilesViewData.asOneLineString();

            foreach (string mod in this.dataFilesViewData.GenerateModSetting().EnumerateMods())
            {
                this.supportModsViewData.AddMod(mod);
            }
            this.supportModsLabel.Text = this.supportModsViewData.asOneLineString();


            this.texturesViewData = new ViewDataTextures(
                new TextureEnableStateRegistry(),
                Program.TextureProvider,
                new TextureOperatorFileSystem(new TextureRegistry(), Program.TextureProvider));

            this.texturesLabel.Text = this.texturesViewData.asOneLineString();
        }
Пример #2
0
        private void editTexturesBtn_Click(object sender, EventArgs e)
        {
            var dialog = new EditTexturesForm();

            dialog.Owner = this;
            dialog.SetData(this.texturesViewData);
            dialog.ShowDialog();
            if (dialog.DialogResult == DialogResult.OK)
            {
                this.texturesViewData = dialog.GetData();
                texturesLabel.Text    = this.texturesViewData.asOneLineString();
            }
        }