예제 #1
0
        //=====================================================================
        // ICloneable implementation

        /// <summary>
        /// Clone this object
        /// </summary>
        /// <returns>A clone of the object</returns>
        public object Clone()
        {
            ContentFileEditor clone = new ContentFileEditor();

            clone.Description     = description;
            clone.Arguments       = arguments;
            clone.Extensions      = extensions;
            clone.ApplicationPath = new FilePath(
                applicationPath.PersistablePath, null);
            clone.StartupFolder = new FolderPath(
                startupFolder.PersistablePath, null);

            return(clone);
        }
예제 #2
0
        //=====================================================================

        /// <summary>
        /// Add a new content editor definition
        /// </summary>
        /// <param name="sender">The sender of the event</param>
        /// <param name="e">The event arguments</param>
        private void btnAddFile_Click(object sender, EventArgs e)
        {
            ContentFileEditor newItem = new ContentFileEditor();

            lbContentEditors.Items.Add(newItem);
            pgProps.Enabled = btnDelete.Enabled = true;
            lbContentEditors.SelectedIndex = lbContentEditors.Items.Count - 1;
            wasModified = true;
        }
예제 #3
0
        //=====================================================================
        // ICloneable implementation

        /// <summary>
        /// Clone this object
        /// </summary>
        /// <returns>A clone of the object</returns>
        public object Clone()
        {
            ContentFileEditor clone = new ContentFileEditor();
            clone.Description = description;
            clone.Arguments = arguments;
            clone.Extensions = extensions;
            clone.ApplicationPath = new FilePath(
                applicationPath.PersistablePath, null);
            clone.StartupFolder = new FolderPath(
                startupFolder.PersistablePath, null);

            return clone;
        }