コード例 #1
0
        public PresetsPage(StartWindow startWindow, MinecraftVersion version)
        {
            ReferenceMain = startWindow;
            Version       = version;

            InitializeComponent();

            this.Text             = $"{Version.Name} : Presets";
            VersionNameLabel.Text = Version.Name;
        }
コード例 #2
0
        /// <summary>
        /// Constructor of an editor instance of the CreateVersion window.
        /// </summary>
        /// <param name="main"> Gets the instance of the StartWindow that created this window. </param>
        /// <param name="isEdit"> True if the window is editing an existing Version. </param>
        /// <param name="version"> The version this window is editing. </param>
        public CreateVersion(StartWindow main, bool isEdit, MinecraftVersion version, int index)
        {
            ReferenceMain = main;
            IsEdit        = isEdit;
            VersionIndex  = index;

            InitializeComponent();

            this.Text = "Edit Version";

            if (IsEdit)
            {
                Version = version;

                VersionNameTextBox.Text     = Version.Name;
                ActiveModsPathTextBox.Text  = Version.ActiveFolderPath;
                StorageModsPathTextBox.Text = Version.StorageFolderPath;

                CreateVersionButton.Text = "Save";
            }
        }
コード例 #3
0
        /// <summary>
        /// Constructor of a creator instance of the CreateVersion window.
        /// </summary>
        /// <param name="main"> Gets the instance of the StartWindow that created this window. </param>
        public CreateVersion(StartWindow main)
        {
            ReferenceMain = main;

            InitializeComponent();
        }