started work on texture sets

This commit is contained in:
codeimp 2008-10-01 08:21:10 +00:00
parent edee6a40c2
commit 6659577b27
14 changed files with 754 additions and 185 deletions

View file

@ -3650,3 +3650,13 @@ thingtypes
9046 = "Sector Secret";
}
}
texturesets
{
startan
{
name = "Startans";
filter0 = "START*";
}
}

View file

@ -346,6 +346,12 @@
<Compile Include="Controls\TextureSelectorControl.cs">
<SubType>UserControl</SubType>
</Compile>
<Compile Include="Windows\TextureSetForm.cs">
<SubType>Form</SubType>
</Compile>
<Compile Include="Windows\TextureSetForm.Designer.cs">
<DependentUpon>TextureSetForm.cs</DependentUpon>
</Compile>
<Compile Include="Windows\ThingEditForm.cs">
<SubType>Form</SubType>
</Compile>
@ -640,6 +646,10 @@
<SubType>Designer</SubType>
<DependentUpon>TextEditForm.cs</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="Windows\TextureSetForm.resx">
<SubType>Designer</SubType>
<DependentUpon>TextureSetForm.cs</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="Windows\ThingEditForm.resx">
<SubType>Designer</SubType>
<DependentUpon>ThingEditForm.cs</DependentUpon>

View file

@ -46,7 +46,8 @@ namespace CodeImp.DoomBuilder.Config
private bool customparameters;
private int testskill;
private List<ThingsFilter> thingsfilters;
private List<TextureSet> texturesets;
#endregion
#region ================== Properties
@ -62,6 +63,7 @@ namespace CodeImp.DoomBuilder.Config
public int TestSkill { get { return testskill; } set { testskill = value; } }
public bool CustomParameters { get { return customparameters; } set { customparameters = value; } }
internal ICollection<ThingsFilter> ThingsFilters { get { return thingsfilters; } }
public List<TextureSet> TextureSets { get { return texturesets; } }
#endregion
@ -94,6 +96,14 @@ namespace CodeImp.DoomBuilder.Config
{
thingsfilters.Add(new ThingsFilter(General.Settings.Config, "configurations." + settingskey + ".thingsfilters." + de.Key));
}
// Make list of texture sets
texturesets = new List<TextureSet>();
IDictionary sets = General.Settings.ReadSetting("configurations." + settingskey + ".texturesets", new Hashtable());
foreach(DictionaryEntry de in sets)
{
texturesets.Add(new DefinedTextureSet(General.Settings.Config, "configurations." + settingskey + ".texturesets." + de.Key));
}
}
// Constructor
@ -130,6 +140,13 @@ namespace CodeImp.DoomBuilder.Config
thingsfilters[i].WriteSettings(General.Settings.Config,
"configurations." + settingskey + ".thingsfilters.filter" + i.ToString(CultureInfo.InvariantCulture));
}
// Write texturesets to configuration
for(int i = 0; i < texturesets.Count; i++)
{
texturesets[i].WriteToConfig(General.Settings.Config,
"configurations." + settingskey + ".texturesets.set" + i.ToString(CultureInfo.InvariantCulture));
}
}
// String representation
@ -153,6 +170,8 @@ namespace CodeImp.DoomBuilder.Config
ci.testparameters = this.testparameters;
ci.customparameters = this.customparameters;
ci.testskill = this.testskill;
ci.texturesets = new List<TextureSet>();
foreach(TextureSet s in this.texturesets) ci.texturesets.Add(s.Copy());
return ci;
}
@ -170,6 +189,23 @@ namespace CodeImp.DoomBuilder.Config
this.testparameters = ci.testparameters;
this.customparameters = ci.customparameters;
this.testskill = ci.testskill;
this.texturesets = new List<TextureSet>();
foreach(TextureSet s in ci.texturesets) this.texturesets.Add(s.Copy());
}
// This applies the defaults
public void ApplyDefaults()
{
// No texture sets?
if(texturesets.Count == 0)
{
// Copy the default texture sets from the game configuration
foreach(TextureSet s in General.Map.Config.TextureSets)
{
// Add a copy to our list
texturesets.Add(s.Copy());
}
}
}
#endregion

View file

@ -56,7 +56,7 @@ namespace CodeImp.DoomBuilder.Config
foreach(DictionaryEntry de in dic)
{
// If not the name of this texture set, add value as filter
if(de.Key.ToString() != "name") filters.Add(de.Value.ToString());
if(de.Key.ToString() != "name") filters.Add(de.Value.ToString().ToUpperInvariant());
}
}
@ -85,7 +85,7 @@ namespace CodeImp.DoomBuilder.Config
for(int i = 0; i < filters.Count; i++)
{
// Add filters
dic.Add(i.ToString(), filters[i]);
dic.Add("filter" + i.ToString(), filters[i].ToUpperInvariant());
}
// Write to config
@ -101,8 +101,11 @@ namespace CodeImp.DoomBuilder.Config
StringBuilder regexstr = new StringBuilder("");
foreach(string s in filters)
{
// Make sure filter is in uppercase
string ss = s.ToUpperInvariant();
// Replace the * with the regex code
string ss = s.Replace("*", ".*?");
ss = ss.Replace("*", ".*?");
// Escape other regex characters, except the ?
ss = ss.Replace("+", "\\+");
@ -133,8 +136,7 @@ namespace CodeImp.DoomBuilder.Config
// Make the regex
regex = new Regex(regexstr.ToString(), RegexOptions.Compiled |
RegexOptions.CultureInvariant |
RegexOptions.IgnoreCase);
RegexOptions.CultureInvariant);
}
// This matches a name against the regex and adds a texture to
@ -142,7 +144,7 @@ namespace CodeImp.DoomBuilder.Config
internal virtual bool Add(ImageData image)
{
// Check against regex
if(regex.IsMatch(image.Name))
if(regex.IsMatch(image.Name.ToUpperInvariant()))
{
// Matches! Add it.
return base.Add(image);
@ -154,6 +156,22 @@ namespace CodeImp.DoomBuilder.Config
}
}
// Duplication
internal override TextureSet Copy()
{
// Make a copy
DefinedTextureSet s = new DefinedTextureSet(this.name);
s.filters = new List<string>(this.filters);
return s;
}
// This applies the filters and name of one set to this one
internal override void Apply(TextureSet set)
{
this.name = set.Name;
this.filters = new List<string>(set.Filters);
}
#endregion
}
}

View file

@ -98,6 +98,9 @@ namespace CodeImp.DoomBuilder.Config
// Enums
private Dictionary<string, EnumList> enums;
// Default Texture Sets
private List<TextureSet> texturesets;
#endregion
#region ================== Properties
@ -157,6 +160,9 @@ namespace CodeImp.DoomBuilder.Config
// Enums
public IDictionary<string, EnumList> Enums { get { return enums; } }
// Texture Sets
internal List<TextureSet> TextureSets { get { return texturesets; } }
#endregion
@ -184,7 +190,8 @@ namespace CodeImp.DoomBuilder.Config
this.geneffectoptions = new List<GeneralizedOption>();
this.enums = new Dictionary<string, EnumList>();
this.skills = new List<SkillInfo>();
this.texturesets = new List<TextureSet>();
// Read general settings
configname = cfg.ReadSetting("game", "<unnamed game>");
enginename = cfg.ReadSetting("engine", "");
@ -243,6 +250,9 @@ namespace CodeImp.DoomBuilder.Config
sidedeffields = LoadUniversalFields("sidedef");
thingfields = LoadUniversalFields("thing");
vertexfields = LoadUniversalFields("vertex");
// Texture sets
LoadTextureSets();
}
// Destructor
@ -578,6 +588,20 @@ namespace CodeImp.DoomBuilder.Config
}
}
// Texture Sets
private void LoadTextureSets()
{
IDictionary dic;
// Get sets
dic = cfg.ReadSetting("texturesets", new Hashtable());
foreach(DictionaryEntry de in dic)
{
TextureSet s = new DefinedTextureSet(cfg, "texturesets." + de.Key.ToString());
texturesets.Add(s);
}
}
#endregion
#region ================== Methods

View file

@ -50,14 +50,5 @@ namespace CodeImp.DoomBuilder.Config
}
#endregion
#region ================== Methods
// This does absolutely nothing
internal override void WriteToConfig(Configuration cfg, string path)
{
}
#endregion
}
}

View file

@ -33,7 +33,7 @@ using System.Collections.Specialized;
namespace CodeImp.DoomBuilder.Config
{
internal abstract class TextureSet
public abstract class TextureSet
{
#region ================== Variables
@ -65,7 +65,7 @@ namespace CodeImp.DoomBuilder.Config
#region ================== Methods
// This writes the texture set to configuration
internal abstract void WriteToConfig(Configuration cfg, string path);
internal virtual void WriteToConfig(Configuration cfg, string path) { }
// This resets the matches and recreates the regex
internal virtual void Reset()
@ -103,6 +103,10 @@ namespace CodeImp.DoomBuilder.Config
return name;
}
// This is optional
internal virtual TextureSet Copy() { return null; }
internal virtual void Apply(TextureSet set) { }
#endregion
}
}

View file

@ -216,6 +216,7 @@ namespace CodeImp.DoomBuilder
General.WriteLogLine("Loading game configuration...");
configinfo = General.GetConfigurationInfo(options.ConfigFile);
config = new GameConfiguration(General.LoadGameConfiguration(options.ConfigFile));
configinfo.ApplyDefaults();
General.Plugins.GameConfigurationChanged();
// Create map data
@ -286,6 +287,7 @@ namespace CodeImp.DoomBuilder
General.WriteLogLine("Loading game configuration...");
configinfo = General.GetConfigurationInfo(options.ConfigFile);
config = new GameConfiguration(General.LoadGameConfiguration(options.ConfigFile));
configinfo.ApplyDefaults();
General.Plugins.GameConfigurationChanged();
// Create map data
@ -1062,6 +1064,7 @@ namespace CodeImp.DoomBuilder
General.WriteLogLine("Loading game configuration...");
configinfo = General.GetConfigurationInfo(options.ConfigFile);
config = new GameConfiguration(General.LoadGameConfiguration(options.ConfigFile));
configinfo.ApplyDefaults();
General.Plugins.GameConfigurationChanged();
// Setup new map format IO

View file

@ -56,17 +56,17 @@ namespace CodeImp.DoomBuilder.Windows
this.labelresult = new System.Windows.Forms.Label();
this.testparameters = new System.Windows.Forms.TextBox();
this.testapplication = new System.Windows.Forms.TextBox();
this.tabtextures = new System.Windows.Forms.TabPage();
this.restoretexturesets = new System.Windows.Forms.Button();
this.edittextureset = new System.Windows.Forms.Button();
this.pastetexturesets = new System.Windows.Forms.Button();
this.copytexturesets = new System.Windows.Forms.Button();
this.removetextureset = new System.Windows.Forms.Button();
this.addtextureset = new System.Windows.Forms.Button();
this.listtextures = new System.Windows.Forms.ListBox();
this.listconfigs = new System.Windows.Forms.ListView();
this.columnname = new System.Windows.Forms.ColumnHeader();
this.testprogramdialog = new System.Windows.Forms.OpenFileDialog();
this.tabtextures = new System.Windows.Forms.TabPage();
this.listtextures = new System.Windows.Forms.ListBox();
this.addtextureset = new System.Windows.Forms.Button();
this.removetextureset = new System.Windows.Forms.Button();
this.copytexturesets = new System.Windows.Forms.Button();
this.pastetexturesets = new System.Windows.Forms.Button();
this.edittextureset = new System.Windows.Forms.Button();
this.restoretexturesets = new System.Windows.Forms.Button();
label5 = new System.Windows.Forms.Label();
label6 = new System.Windows.Forms.Label();
label3 = new System.Windows.Forms.Label();
@ -164,6 +164,17 @@ namespace CodeImp.DoomBuilder.Windows
label8.TabIndex = 34;
label8.Text = "Skill Level:";
//
// label4
//
label4.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
label4.AutoEllipsis = true;
label4.Location = new System.Drawing.Point(12, 15);
label4.Name = "label4";
label4.Size = new System.Drawing.Size(394, 75);
label4.TabIndex = 24;
label4.Text = resources.GetString("label4.Text");
//
// labelparameters
//
this.labelparameters.AutoSize = true;
@ -399,6 +410,98 @@ namespace CodeImp.DoomBuilder.Windows
this.testapplication.TabIndex = 25;
this.testapplication.TextChanged += new System.EventHandler(this.testapplication_TextChanged);
//
// tabtextures
//
this.tabtextures.Controls.Add(this.restoretexturesets);
this.tabtextures.Controls.Add(this.edittextureset);
this.tabtextures.Controls.Add(this.pastetexturesets);
this.tabtextures.Controls.Add(this.copytexturesets);
this.tabtextures.Controls.Add(this.removetextureset);
this.tabtextures.Controls.Add(this.addtextureset);
this.tabtextures.Controls.Add(this.listtextures);
this.tabtextures.Controls.Add(label4);
this.tabtextures.Font = new System.Drawing.Font("Arial", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.tabtextures.Location = new System.Drawing.Point(4, 23);
this.tabtextures.Name = "tabtextures";
this.tabtextures.Size = new System.Drawing.Size(415, 318);
this.tabtextures.TabIndex = 3;
this.tabtextures.Text = "Textures";
this.tabtextures.UseVisualStyleBackColor = true;
//
// restoretexturesets
//
this.restoretexturesets.Location = new System.Drawing.Point(15, 275);
this.restoretexturesets.Name = "restoretexturesets";
this.restoretexturesets.Size = new System.Drawing.Size(140, 24);
this.restoretexturesets.TabIndex = 31;
this.restoretexturesets.Text = "Add Default Sets";
this.restoretexturesets.UseVisualStyleBackColor = true;
//
// edittextureset
//
this.edittextureset.Enabled = false;
this.edittextureset.Location = new System.Drawing.Point(88, 237);
this.edittextureset.Name = "edittextureset";
this.edittextureset.Size = new System.Drawing.Size(67, 24);
this.edittextureset.TabIndex = 30;
this.edittextureset.Text = "Edit...";
this.edittextureset.UseVisualStyleBackColor = true;
this.edittextureset.Click += new System.EventHandler(this.edittextureset_Click);
//
// pastetexturesets
//
this.pastetexturesets.Enabled = false;
this.pastetexturesets.Location = new System.Drawing.Point(339, 237);
this.pastetexturesets.Name = "pastetexturesets";
this.pastetexturesets.Size = new System.Drawing.Size(58, 24);
this.pastetexturesets.TabIndex = 29;
this.pastetexturesets.Text = "Paste";
this.pastetexturesets.UseVisualStyleBackColor = true;
//
// copytexturesets
//
this.copytexturesets.Enabled = false;
this.copytexturesets.Location = new System.Drawing.Point(275, 237);
this.copytexturesets.Name = "copytexturesets";
this.copytexturesets.Size = new System.Drawing.Size(58, 24);
this.copytexturesets.TabIndex = 28;
this.copytexturesets.Text = "Copy";
this.copytexturesets.UseVisualStyleBackColor = true;
//
// removetextureset
//
this.removetextureset.Enabled = false;
this.removetextureset.Location = new System.Drawing.Point(161, 237);
this.removetextureset.Name = "removetextureset";
this.removetextureset.Size = new System.Drawing.Size(68, 24);
this.removetextureset.TabIndex = 27;
this.removetextureset.Text = "Remove";
this.removetextureset.UseVisualStyleBackColor = true;
//
// addtextureset
//
this.addtextureset.Location = new System.Drawing.Point(15, 237);
this.addtextureset.Name = "addtextureset";
this.addtextureset.Size = new System.Drawing.Size(67, 24);
this.addtextureset.TabIndex = 26;
this.addtextureset.Text = "Add...";
this.addtextureset.UseVisualStyleBackColor = true;
this.addtextureset.Click += new System.EventHandler(this.addtextureset_Click);
//
// listtextures
//
this.listtextures.ColumnWidth = 120;
this.listtextures.IntegralHeight = false;
this.listtextures.ItemHeight = 14;
this.listtextures.Location = new System.Drawing.Point(15, 84);
this.listtextures.MultiColumn = true;
this.listtextures.Name = "listtextures";
this.listtextures.SelectionMode = System.Windows.Forms.SelectionMode.MultiExtended;
this.listtextures.Size = new System.Drawing.Size(382, 147);
this.listtextures.Sorted = true;
this.listtextures.TabIndex = 25;
this.listtextures.SelectedIndexChanged += new System.EventHandler(this.listtextures_SelectedIndexChanged);
//
// listconfigs
//
this.listconfigs.Columns.AddRange(new System.Windows.Forms.ColumnHeader[] {
@ -429,107 +532,6 @@ namespace CodeImp.DoomBuilder.Windows
this.testprogramdialog.Filter = "Executable Files (*.exe)|*.exe|Batch Files (*.bat)|*.bat";
this.testprogramdialog.Title = "Browse Test Program";
//
// tabtextures
//
this.tabtextures.Controls.Add(this.restoretexturesets);
this.tabtextures.Controls.Add(this.edittextureset);
this.tabtextures.Controls.Add(this.pastetexturesets);
this.tabtextures.Controls.Add(this.copytexturesets);
this.tabtextures.Controls.Add(this.removetextureset);
this.tabtextures.Controls.Add(this.addtextureset);
this.tabtextures.Controls.Add(this.listtextures);
this.tabtextures.Controls.Add(label4);
this.tabtextures.Font = new System.Drawing.Font("Arial", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.tabtextures.Location = new System.Drawing.Point(4, 23);
this.tabtextures.Name = "tabtextures";
this.tabtextures.Size = new System.Drawing.Size(415, 318);
this.tabtextures.TabIndex = 3;
this.tabtextures.Text = "Textures";
this.tabtextures.UseVisualStyleBackColor = true;
//
// label4
//
label4.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
label4.AutoEllipsis = true;
label4.Location = new System.Drawing.Point(12, 15);
label4.Name = "label4";
label4.Size = new System.Drawing.Size(394, 75);
label4.TabIndex = 24;
label4.Text = resources.GetString("label4.Text");
//
// listtextures
//
this.listtextures.ColumnWidth = 120;
this.listtextures.IntegralHeight = false;
this.listtextures.ItemHeight = 14;
this.listtextures.Location = new System.Drawing.Point(15, 93);
this.listtextures.MultiColumn = true;
this.listtextures.Name = "listtextures";
this.listtextures.ScrollAlwaysVisible = true;
this.listtextures.SelectionMode = System.Windows.Forms.SelectionMode.MultiExtended;
this.listtextures.Size = new System.Drawing.Size(382, 138);
this.listtextures.Sorted = true;
this.listtextures.TabIndex = 25;
//
// addtextureset
//
this.addtextureset.Location = new System.Drawing.Point(15, 237);
this.addtextureset.Name = "addtextureset";
this.addtextureset.Size = new System.Drawing.Size(67, 24);
this.addtextureset.TabIndex = 26;
this.addtextureset.Text = "Add...";
this.addtextureset.UseVisualStyleBackColor = true;
//
// removetextureset
//
this.removetextureset.Enabled = false;
this.removetextureset.Location = new System.Drawing.Point(161, 237);
this.removetextureset.Name = "removetextureset";
this.removetextureset.Size = new System.Drawing.Size(68, 24);
this.removetextureset.TabIndex = 27;
this.removetextureset.Text = "Remove";
this.removetextureset.UseVisualStyleBackColor = true;
//
// copytexturesets
//
this.copytexturesets.Enabled = false;
this.copytexturesets.Location = new System.Drawing.Point(275, 237);
this.copytexturesets.Name = "copytexturesets";
this.copytexturesets.Size = new System.Drawing.Size(58, 24);
this.copytexturesets.TabIndex = 28;
this.copytexturesets.Text = "Copy";
this.copytexturesets.UseVisualStyleBackColor = true;
//
// pastetexturesets
//
this.pastetexturesets.Enabled = false;
this.pastetexturesets.Location = new System.Drawing.Point(339, 237);
this.pastetexturesets.Name = "pastetexturesets";
this.pastetexturesets.Size = new System.Drawing.Size(58, 24);
this.pastetexturesets.TabIndex = 29;
this.pastetexturesets.Text = "Paste";
this.pastetexturesets.UseVisualStyleBackColor = true;
//
// edittextureset
//
this.edittextureset.Enabled = false;
this.edittextureset.Location = new System.Drawing.Point(88, 237);
this.edittextureset.Name = "edittextureset";
this.edittextureset.Size = new System.Drawing.Size(67, 24);
this.edittextureset.TabIndex = 30;
this.edittextureset.Text = "Edit...";
this.edittextureset.UseVisualStyleBackColor = true;
//
// restoretexturesets
//
this.restoretexturesets.Location = new System.Drawing.Point(15, 275);
this.restoretexturesets.Name = "restoretexturesets";
this.restoretexturesets.Size = new System.Drawing.Size(140, 24);
this.restoretexturesets.TabIndex = 31;
this.restoretexturesets.Text = "Add Default Categories";
this.restoretexturesets.UseVisualStyleBackColor = true;
//
// ConfigForm
//
this.AcceptButton = this.apply;

View file

@ -38,6 +38,7 @@ namespace CodeImp.DoomBuilder.Windows
{
// Variables
private GameConfiguration gameconfig;
private ConfigurationInfo configinfo;
// Constructor
public ConfigForm()
@ -81,7 +82,6 @@ namespace CodeImp.DoomBuilder.Windows
// Configuration item selected
private void listconfigs_SelectedIndexChanged(object sender, EventArgs e)
{
ConfigurationInfo ci;
NodebuilderInfo ni;
// Item selected?
@ -91,13 +91,13 @@ namespace CodeImp.DoomBuilder.Windows
tabs.Enabled = true;
// Get config info of selected item
ci = listconfigs.SelectedItems[0].Tag as ConfigurationInfo;
configinfo = listconfigs.SelectedItems[0].Tag as ConfigurationInfo;
// Load the game configuration
gameconfig = new GameConfiguration(General.LoadGameConfiguration(ci.Filename));
gameconfig = new GameConfiguration(General.LoadGameConfiguration(configinfo.Filename));
// Fill resources list
configdata.EditResourceLocationList(ci.Resources);
configdata.EditResourceLocationList(configinfo.Resources);
// Go for all nodebuilder save items
nodebuildersave.SelectedIndex = -1;
@ -107,7 +107,7 @@ namespace CodeImp.DoomBuilder.Windows
ni = nodebuildersave.Items[i] as NodebuilderInfo;
// Item matches configuration setting?
if(string.Compare(ni.Name, ci.NodebuilderSave, false) == 0)
if(string.Compare(ni.Name, configinfo.NodebuilderSave, false) == 0)
{
// Select this item
nodebuildersave.SelectedIndex = i;
@ -123,7 +123,7 @@ namespace CodeImp.DoomBuilder.Windows
ni = nodebuildertest.Items[i] as NodebuilderInfo;
// Item matches configuration setting?
if(string.Compare(ni.Name, ci.NodebuilderTest, false) == 0)
if(string.Compare(ni.Name, configinfo.NodebuilderTest, false) == 0)
{
// Select this item
nodebuildertest.SelectedIndex = i;
@ -136,13 +136,17 @@ namespace CodeImp.DoomBuilder.Windows
skill.AddInfo(gameconfig.Skills.ToArray());
// Set test application and parameters
if(!ci.CustomParameters) ci.TestParameters = gameconfig.TestParameters;
testapplication.Text = ci.TestProgram;
testparameters.Text = ci.TestParameters;
int skilllevel = ci.TestSkill;
if(!configinfo.CustomParameters) configinfo.TestParameters = gameconfig.TestParameters;
testapplication.Text = configinfo.TestProgram;
testparameters.Text = configinfo.TestParameters;
int skilllevel = configinfo.TestSkill;
skill.Value = skilllevel - 1;
skill.Value = skilllevel;
customparameters.Checked = ci.CustomParameters;
customparameters.Checked = configinfo.CustomParameters;
// Fill texture sets list
listtextures.Items.Clear();
listtextures.Items.AddRange(configinfo.TextureSets.ToArray());
}
}
@ -153,6 +157,8 @@ namespace CodeImp.DoomBuilder.Windows
if(listconfigs.SelectedItems.Count == 0)
{
// Disable panels
gameconfig = null;
configinfo = null;
configdata.FixedResourceLocationList(new DataLocationList());
configdata.EditResourceLocationList(new DataLocationList());
nodebuildersave.SelectedIndex = -1;
@ -163,7 +169,6 @@ namespace CodeImp.DoomBuilder.Windows
skill.ClearInfo();
customparameters.Checked = false;
tabs.Enabled = false;
gameconfig = null;
}
}
@ -176,69 +181,55 @@ namespace CodeImp.DoomBuilder.Windows
// Resource locations changed
private void resourcelocations_OnContentChanged()
{
ConfigurationInfo ci;
// Leave when no configuration selected
if(listconfigs.SelectedItems.Count == 0) return;
if(configinfo == null) return;
// Apply to selected configuration
ci = listconfigs.SelectedItems[0].Tag as ConfigurationInfo;
ci.Resources.Clear();
ci.Resources.AddRange(configdata.GetResources());
configinfo.Resources.Clear();
configinfo.Resources.AddRange(configdata.GetResources());
}
// Nodebuilder selection changed
private void nodebuildersave_SelectedIndexChanged(object sender, EventArgs e)
{
ConfigurationInfo ci;
// Leave when no configuration selected
if(listconfigs.SelectedItems.Count == 0) return;
if(configinfo == null) return;
// Apply to selected configuration
ci = listconfigs.SelectedItems[0].Tag as ConfigurationInfo;
if(nodebuildersave.SelectedItem != null)
ci.NodebuilderSave = (nodebuildersave.SelectedItem as NodebuilderInfo).Name;
configinfo.NodebuilderSave = (nodebuildersave.SelectedItem as NodebuilderInfo).Name;
}
// Nodebuilder selection changed
private void nodebuildertest_SelectedIndexChanged(object sender, EventArgs e)
{
ConfigurationInfo ci;
// Leave when no configuration selected
if(listconfigs.SelectedItems.Count == 0) return;
if(configinfo == null) return;
// Apply to selected configuration
ci = listconfigs.SelectedItems[0].Tag as ConfigurationInfo;
if(nodebuildertest.SelectedItem != null)
ci.NodebuilderTest = (nodebuildertest.SelectedItem as NodebuilderInfo).Name;
configinfo.NodebuilderTest = (nodebuildertest.SelectedItem as NodebuilderInfo).Name;
}
// Test application changed
private void testapplication_TextChanged(object sender, EventArgs e)
{
ConfigurationInfo ci;
// Leave when no configuration selected
if(listconfigs.SelectedItems.Count == 0) return;
if(configinfo == null) return;
// Apply to selected configuration
ci = listconfigs.SelectedItems[0].Tag as ConfigurationInfo;
ci.TestProgram = testapplication.Text;
configinfo.TestProgram = testapplication.Text;
}
// Test parameters changed
private void testparameters_TextChanged(object sender, EventArgs e)
{
ConfigurationInfo ci;
// Leave when no configuration selected
if(listconfigs.SelectedItems.Count == 0) return;
if(configinfo == null) return;
// Apply to selected configuration
ci = listconfigs.SelectedItems[0].Tag as ConfigurationInfo;
ci.TestParameters = testparameters.Text;
configinfo = listconfigs.SelectedItems[0].Tag as ConfigurationInfo;
configinfo.TestParameters = testparameters.Text;
// Show example result
CreateParametersExample();
@ -308,14 +299,11 @@ namespace CodeImp.DoomBuilder.Windows
// Customize parameters (un)checked
private void customparameters_CheckedChanged(object sender, EventArgs e)
{
ConfigurationInfo ci;
// Leave when no configuration selected
if(listconfigs.SelectedItems.Count == 0) return;
if(configinfo == null) return;
// Apply to selected configuration
ci = listconfigs.SelectedItems[0].Tag as ConfigurationInfo;
ci.CustomParameters = customparameters.Checked;
configinfo.CustomParameters = customparameters.Checked;
// Update interface
labelparameters.Visible = customparameters.Checked;
@ -341,16 +329,49 @@ namespace CodeImp.DoomBuilder.Windows
// Skill changes
private void skill_ValueChanges(object sender, EventArgs e)
{
ConfigurationInfo ci;
// Leave when no configuration selected
if(listconfigs.SelectedItems.Count == 0) return;
if(configinfo == null) return;
// Apply to selected configuration
ci = listconfigs.SelectedItems[0].Tag as ConfigurationInfo;
ci.TestSkill = skill.Value;
configinfo.TestSkill = skill.Value;
CreateParametersExample();
}
// Make new texture set
private void addtextureset_Click(object sender, EventArgs e)
{
DefinedTextureSet s = new DefinedTextureSet("New Texture Set");
TextureSetForm form = new TextureSetForm();
form.Setup(s);
if(form.ShowDialog(this) == DialogResult.OK)
{
// Add to texture sets
configinfo.TextureSets.Add(s);
listtextures.Items.Add(s);
}
}
// Edit texture set
private void edittextureset_Click(object sender, EventArgs e)
{
// Texture Set selected?
if(listtextures.SelectedItem is DefinedTextureSet)
{
DefinedTextureSet s = (listtextures.SelectedItem as DefinedTextureSet);
TextureSetForm form = new TextureSetForm();
form.Setup(s);
form.ShowDialog(this);
}
}
// Texture Set selected/deselected
private void listtextures_SelectedIndexChanged(object sender, EventArgs e)
{
edittextureset.Enabled = (listtextures.SelectedItem is DefinedTextureSet);
removetextureset.Enabled = (listtextures.SelectedItem is DefinedTextureSet);
copytexturesets.Enabled = (listtextures.SelectedItem is DefinedTextureSet);
pastetexturesets.Enabled = (listtextures.SelectedItem is DefinedTextureSet);
}
}
}

View file

@ -168,6 +168,15 @@
<metadata name="label8.GenerateMember" type="System.Boolean, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>False</value>
</metadata>
<metadata name="label4.Locked" type="System.Boolean, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="label4.GenerateMember" type="System.Boolean, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>False</value>
</metadata>
<data name="label4.Text" xml:space="preserve">
<value>Texture Sets are a way to group textures and flats into categories, so that you can easily find a texture for the specific style or purpose you need by selecting one of the categories. Textures that are not in any category are automatically shown in the "Others" category.</value>
</data>
<metadata name="labelparameters.Locked" type="System.Boolean, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
@ -246,15 +255,6 @@
<metadata name="listtextures.Locked" type="System.Boolean, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="label4.Locked" type="System.Boolean, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="label4.GenerateMember" type="System.Boolean, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>False</value>
</metadata>
<data name="label4.Text" xml:space="preserve">
<value>Texture Sets are a way to group textures and flats into categories, so that you can easily find a texture for the specific style or purpose you need by selecting one of the categories. Textures that are not in any category are automatically shown in the "Others" category.</value>
</data>
<metadata name="listconfigs.Locked" type="System.Boolean, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>

208
Source/Windows/TextureSetForm.Designer.cs generated Normal file
View file

@ -0,0 +1,208 @@
namespace CodeImp.DoomBuilder.Windows
{
partial class TextureSetForm
{
/// <summary>
/// Required designer variable.
/// </summary>
private System.ComponentModel.IContainer components = null;
/// <summary>
/// Clean up any resources being used.
/// </summary>
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
protected override void Dispose(bool disposing)
{
if(disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
}
#region Windows Form Designer generated code
/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
private void InitializeComponent()
{
this.label1 = new System.Windows.Forms.Label();
this.name = new System.Windows.Forms.TextBox();
this.filters = new System.Windows.Forms.ListView();
this.filtercolumn = new System.Windows.Forms.ColumnHeader();
this.label2 = new System.Windows.Forms.Label();
this.label3 = new System.Windows.Forms.Label();
this.label4 = new System.Windows.Forms.Label();
this.apply = new System.Windows.Forms.Button();
this.cancel = new System.Windows.Forms.Button();
this.addfilter = new System.Windows.Forms.Button();
this.removefilter = new System.Windows.Forms.Button();
this.groupBox1 = new System.Windows.Forms.GroupBox();
this.groupBox1.SuspendLayout();
this.SuspendLayout();
//
// label1
//
this.label1.AutoSize = true;
this.label1.Location = new System.Drawing.Point(30, 24);
this.label1.Name = "label1";
this.label1.Size = new System.Drawing.Size(37, 14);
this.label1.TabIndex = 0;
this.label1.Text = "Name:";
//
// name
//
this.name.Location = new System.Drawing.Point(73, 21);
this.name.Name = "name";
this.name.Size = new System.Drawing.Size(179, 20);
this.name.TabIndex = 1;
//
// filters
//
this.filters.Columns.AddRange(new System.Windows.Forms.ColumnHeader[] {
this.filtercolumn});
this.filters.HeaderStyle = System.Windows.Forms.ColumnHeaderStyle.None;
this.filters.HideSelection = false;
this.filters.LabelEdit = true;
this.filters.Location = new System.Drawing.Point(21, 110);
this.filters.Name = "filters";
this.filters.ShowGroups = false;
this.filters.Size = new System.Drawing.Size(219, 173);
this.filters.TabIndex = 2;
this.filters.UseCompatibleStateImageBehavior = false;
this.filters.View = System.Windows.Forms.View.Details;
//
// filtercolumn
//
this.filtercolumn.Text = "Filter";
this.filtercolumn.Width = 192;
//
// label2
//
this.label2.Location = new System.Drawing.Point(18, 28);
this.label2.Name = "label2";
this.label2.Size = new System.Drawing.Size(248, 42);
this.label2.TabIndex = 3;
this.label2.Text = "Add the names of the textures in this set below. You can use the following wildca" +
"rds:";
//
// label3
//
this.label3.AutoSize = true;
this.label3.Location = new System.Drawing.Point(28, 65);
this.label3.Name = "label3";
this.label3.Size = new System.Drawing.Size(175, 14);
this.label3.TabIndex = 4;
this.label3.Text = "? = matches exactly one character";
//
// label4
//
this.label4.AutoSize = true;
this.label4.Location = new System.Drawing.Point(28, 83);
this.label4.Name = "label4";
this.label4.Size = new System.Drawing.Size(181, 14);
this.label4.TabIndex = 5;
this.label4.Text = "* = matches one or more characters";
//
// apply
//
this.apply.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
this.apply.Location = new System.Drawing.Point(58, 417);
this.apply.Name = "apply";
this.apply.Size = new System.Drawing.Size(105, 25);
this.apply.TabIndex = 6;
this.apply.Text = "OK";
this.apply.UseVisualStyleBackColor = true;
this.apply.Click += new System.EventHandler(this.apply_Click);
//
// cancel
//
this.cancel.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
this.cancel.DialogResult = System.Windows.Forms.DialogResult.Cancel;
this.cancel.Location = new System.Drawing.Point(177, 417);
this.cancel.Name = "cancel";
this.cancel.Size = new System.Drawing.Size(105, 25);
this.cancel.TabIndex = 7;
this.cancel.Text = "Cancel";
this.cancel.UseVisualStyleBackColor = true;
this.cancel.Click += new System.EventHandler(this.cancel_Click);
//
// addfilter
//
this.addfilter.Location = new System.Drawing.Point(21, 289);
this.addfilter.Name = "addfilter";
this.addfilter.Size = new System.Drawing.Size(97, 24);
this.addfilter.TabIndex = 8;
this.addfilter.Text = "Add Texture";
this.addfilter.UseVisualStyleBackColor = true;
//
// removefilter
//
this.removefilter.Location = new System.Drawing.Point(135, 289);
this.removefilter.Name = "removefilter";
this.removefilter.Size = new System.Drawing.Size(105, 24);
this.removefilter.TabIndex = 9;
this.removefilter.Text = "Remove Selection";
this.removefilter.UseVisualStyleBackColor = true;
//
// groupBox1
//
this.groupBox1.Controls.Add(this.removefilter);
this.groupBox1.Controls.Add(this.label4);
this.groupBox1.Controls.Add(this.addfilter);
this.groupBox1.Controls.Add(this.label3);
this.groupBox1.Controls.Add(this.label2);
this.groupBox1.Controls.Add(this.filters);
this.groupBox1.Location = new System.Drawing.Point(12, 60);
this.groupBox1.Name = "groupBox1";
this.groupBox1.Size = new System.Drawing.Size(269, 333);
this.groupBox1.TabIndex = 10;
this.groupBox1.TabStop = false;
this.groupBox1.Text = " Filters ";
//
// TextureSetForm
//
this.AcceptButton = this.apply;
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.None;
this.CancelButton = this.cancel;
this.ClientSize = new System.Drawing.Size(294, 455);
this.Controls.Add(this.cancel);
this.Controls.Add(this.apply);
this.Controls.Add(this.name);
this.Controls.Add(this.label1);
this.Controls.Add(this.groupBox1);
this.Font = new System.Drawing.Font("Arial", 8.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedDialog;
this.MaximizeBox = false;
this.MinimizeBox = false;
this.Name = "TextureSetForm";
this.Opacity = 0;
this.ShowIcon = false;
this.ShowInTaskbar = false;
this.StartPosition = System.Windows.Forms.FormStartPosition.CenterParent;
this.Text = "Edit Texture Set";
this.groupBox1.ResumeLayout(false);
this.groupBox1.PerformLayout();
this.ResumeLayout(false);
this.PerformLayout();
}
#endregion
private System.Windows.Forms.Label label1;
private System.Windows.Forms.TextBox name;
private System.Windows.Forms.ListView filters;
private System.Windows.Forms.Label label2;
private System.Windows.Forms.Label label3;
private System.Windows.Forms.Label label4;
private System.Windows.Forms.Button apply;
private System.Windows.Forms.Button cancel;
private System.Windows.Forms.ColumnHeader filtercolumn;
private System.Windows.Forms.Button addfilter;
private System.Windows.Forms.Button removefilter;
private System.Windows.Forms.GroupBox groupBox1;
}
}

View file

@ -0,0 +1,86 @@
#region ================== Copyright (c) 2007 Pascal vd Heiden
/*
* Copyright (c) 2007 Pascal vd Heiden, www.codeimp.com
* This program is released under GNU General Public License
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
*/
#endregion
#region ================== Namespaces
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
using CodeImp.DoomBuilder.Map;
using CodeImp.DoomBuilder.Data;
using CodeImp.DoomBuilder.IO;
using System.IO;
using CodeImp.DoomBuilder.Config;
using CodeImp.DoomBuilder.Editing;
using CodeImp.DoomBuilder.Controls;
#endregion
namespace CodeImp.DoomBuilder.Windows
{
internal partial class TextureSetForm : DelayedForm
{
// Variables
private DefinedTextureSet textureset;
// Constructor
public TextureSetForm()
{
InitializeComponent();
}
// This initializes the set
public void Setup(DefinedTextureSet set)
{
// Keep reference
textureset = set;
// Set name
name.Text = set.Name;
// Fill filters list
foreach(string s in set.Filters)
filters.Items.Add(s);
}
// OK clicked
private void apply_Click(object sender, EventArgs e)
{
// Apply name
textureset.Name = name.Text;
// Apply filters
textureset.Filters.Clear();
foreach(ListViewItem i in filters.Items) textureset.Filters.Add(i.Text);
// Done
this.DialogResult = DialogResult.OK;
this.Close();
}
// Cancel clicked
private void cancel_Click(object sender, EventArgs e)
{
// Be gone.
this.DialogResult = DialogResult.Cancel;
this.Close();
}
}
}

View file

@ -0,0 +1,156 @@
<?xml version="1.0" encoding="utf-8"?>
<root>
<!--
Microsoft ResX Schema
Version 2.0
The primary goals of this format is to allow a simple XML format
that is mostly human readable. The generation and parsing of the
various data types are done through the TypeConverter classes
associated with the data types.
Example:
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
<value>[base64 mime encoded serialized .NET Framework object]</value>
</data>
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
<comment>This is a comment</comment>
</data>
There are any number of "resheader" rows that contain simple
name/value pairs.
Each data row contains a name, and value. The row also contains a
type or mimetype. Type corresponds to a .NET class that support
text/value conversion through the TypeConverter architecture.
Classes that don't support this are serialized and stored with the
mimetype set.
The mimetype is used for serialized objects, and tells the
ResXResourceReader how to depersist the object. This is currently not
extensible. For a given mimetype the value must be set accordingly:
Note - application/x-microsoft.net.object.binary.base64 is the format
that the ResXResourceWriter will generate, however the reader can
read any of the formats listed below.
mimetype: application/x-microsoft.net.object.binary.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.soap.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.bytearray.base64
value : The object must be serialized into a byte array
: using a System.ComponentModel.TypeConverter
: and then encoded with base64 encoding.
-->
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" use="required" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<metadata name="label1.Locked" type="System.Boolean, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="name.Locked" type="System.Boolean, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="filters.Locked" type="System.Boolean, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="label2.Locked" type="System.Boolean, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="label3.Locked" type="System.Boolean, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="label4.Locked" type="System.Boolean, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="apply.Locked" type="System.Boolean, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="cancel.Locked" type="System.Boolean, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="addfilter.Locked" type="System.Boolean, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="removefilter.Locked" type="System.Boolean, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="groupBox1.Locked" type="System.Boolean, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
<metadata name="$this.Locked" type="System.Boolean, mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<value>True</value>
</metadata>
</root>