Visual Designer:

* foreach iterations are halted once a object has been added to the designer.
This commit is contained in:
Scionwest_cp 2009-11-21 10:21:27 -08:00
parent 89e01e75e1
commit c6c2e4dc9c
4 changed files with 241 additions and 179 deletions

View file

@ -44,6 +44,7 @@ namespace MudDesigner
legalApps.Add(app);
}
}
string filename = "";
foreach (string app in legalApps)
{
@ -53,10 +54,12 @@ namespace MudDesigner
break;
}
}
info.FileName = filename;
#else
info.FileName = appName;
#endif
info.WindowStyle = System.Diagnostics.ProcessWindowStyle.Normal;
info.WorkingDirectory = Application.StartupPath;

View file

@ -47,6 +47,12 @@
<Reference Include="System.Xml" />
</ItemGroup>
<ItemGroup>
<Compile Include="RoomDesigner.cs">
<SubType>UserControl</SubType>
</Compile>
<Compile Include="RoomDesigner.Designer.cs">
<DependentUpon>RoomDesigner.cs</DependentUpon>
</Compile>
<Compile Include="VisualContainer.cs">
<SubType>UserControl</SubType>
</Compile>
@ -56,11 +62,21 @@
<Compile Include="Properties\AssemblyInfo.cs" />
</ItemGroup>
<ItemGroup>
<EmbeddedResource Include="RoomDesigner.resx">
<DependentUpon>RoomDesigner.cs</DependentUpon>
<SubType>Designer</SubType>
</EmbeddedResource>
<EmbeddedResource Include="VisualContainer.resx">
<DependentUpon>VisualContainer.cs</DependentUpon>
<SubType>Designer</SubType>
</EmbeddedResource>
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\MUDEngine\MUDEngine.csproj">
<Project>{33828B3B-F227-4726-8FCD-3D9D780E643D}</Project>
<Name>MUDEngine</Name>
</ProjectReference>
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.

View file

@ -28,43 +28,47 @@
/// </summary>
private void InitializeComponent()
{
System.Windows.Forms.TreeNode treeNode3 = new System.Windows.Forms.TreeNode("Game Objects");
System.Windows.Forms.TreeNode treeNode4 = new System.Windows.Forms.TreeNode("Game", new System.Windows.Forms.TreeNode[] {
treeNode3});
System.Windows.Forms.TreeNode treeNode11 = new System.Windows.Forms.TreeNode("Game Objects");
System.Windows.Forms.TreeNode treeNode12 = new System.Windows.Forms.TreeNode("Game", new System.Windows.Forms.TreeNode[] {
treeNode11});
this.containerMain = new System.Windows.Forms.SplitContainer();
this.panel1 = new System.Windows.Forms.Panel();
this.label1 = new System.Windows.Forms.Label();
this.containerProperties = new System.Windows.Forms.SplitContainer();
this.tabControl1 = new System.Windows.Forms.TabControl();
this.page1 = new System.Windows.Forms.TabPage();
this.panel4 = new System.Windows.Forms.Panel();
this.label4 = new System.Windows.Forms.Label();
this.containerLeftPane = new System.Windows.Forms.SplitContainer();
this.treeProjectExplorer = new System.Windows.Forms.TreeView();
this.panel2 = new System.Windows.Forms.Panel();
this.label2 = new System.Windows.Forms.Label();
this.propertyGrid1 = new System.Windows.Forms.PropertyGrid();
this.panel3 = new System.Windows.Forms.Panel();
this.label3 = new System.Windows.Forms.Label();
this.menuStrip1 = new System.Windows.Forms.MenuStrip();
this.fileToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.closeToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.panel1 = new System.Windows.Forms.Panel();
this.label1 = new System.Windows.Forms.Label();
this.label2 = new System.Windows.Forms.Label();
this.panel2 = new System.Windows.Forms.Panel();
this.label3 = new System.Windows.Forms.Label();
this.panel3 = new System.Windows.Forms.Panel();
this.label4 = new System.Windows.Forms.Label();
this.panel4 = new System.Windows.Forms.Panel();
this.projectToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.createNewObjectToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.toolStripMenuItem1 = new System.Windows.Forms.ToolStripSeparator();
this.refreshObjectBrowserToolStripMenuItem = new System.Windows.Forms.ToolStripMenuItem();
this.flowLayoutPanel1 = new System.Windows.Forms.FlowLayoutPanel();
this.tabControl1 = new System.Windows.Forms.TabControl();
this.page1 = new System.Windows.Forms.TabPage();
this.propertyGrid1 = new System.Windows.Forms.PropertyGrid();
this.treeProjectExplorer = new System.Windows.Forms.TreeView();
this.containerMain.Panel1.SuspendLayout();
this.containerMain.Panel2.SuspendLayout();
this.containerMain.SuspendLayout();
this.panel1.SuspendLayout();
this.containerProperties.Panel1.SuspendLayout();
this.containerProperties.Panel2.SuspendLayout();
this.containerProperties.SuspendLayout();
this.tabControl1.SuspendLayout();
this.panel4.SuspendLayout();
this.containerLeftPane.Panel1.SuspendLayout();
this.containerLeftPane.Panel2.SuspendLayout();
this.containerLeftPane.SuspendLayout();
this.menuStrip1.SuspendLayout();
this.panel1.SuspendLayout();
this.panel2.SuspendLayout();
this.panel3.SuspendLayout();
this.panel4.SuspendLayout();
this.tabControl1.SuspendLayout();
this.menuStrip1.SuspendLayout();
this.SuspendLayout();
//
// containerMain
@ -88,73 +92,6 @@
this.containerMain.SplitterDistance = 133;
this.containerMain.TabIndex = 0;
//
// containerProperties
//
this.containerProperties.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
this.containerProperties.Dock = System.Windows.Forms.DockStyle.Fill;
this.containerProperties.Location = new System.Drawing.Point(0, 0);
this.containerProperties.Name = "containerProperties";
//
// containerProperties.Panel1
//
this.containerProperties.Panel1.Controls.Add(this.tabControl1);
this.containerProperties.Panel1.Controls.Add(this.panel4);
//
// containerProperties.Panel2
//
this.containerProperties.Panel2.Controls.Add(this.containerLeftPane);
this.containerProperties.Size = new System.Drawing.Size(913, 589);
this.containerProperties.SplitterDistance = 667;
this.containerProperties.TabIndex = 0;
//
// containerLeftPane
//
this.containerLeftPane.Dock = System.Windows.Forms.DockStyle.Fill;
this.containerLeftPane.Location = new System.Drawing.Point(0, 0);
this.containerLeftPane.Name = "containerLeftPane";
this.containerLeftPane.Orientation = System.Windows.Forms.Orientation.Horizontal;
//
// containerLeftPane.Panel1
//
this.containerLeftPane.Panel1.Controls.Add(this.treeProjectExplorer);
this.containerLeftPane.Panel1.Controls.Add(this.panel2);
//
// containerLeftPane.Panel2
//
this.containerLeftPane.Panel2.Controls.Add(this.propertyGrid1);
this.containerLeftPane.Panel2.Controls.Add(this.panel3);
this.containerLeftPane.Size = new System.Drawing.Size(240, 587);
this.containerLeftPane.SplitterDistance = 297;
this.containerLeftPane.TabIndex = 0;
//
// menuStrip1
//
this.menuStrip1.BackColor = System.Drawing.Color.Silver;
this.menuStrip1.Items.AddRange(new System.Windows.Forms.ToolStripItem[] {
this.fileToolStripMenuItem});
this.menuStrip1.Location = new System.Drawing.Point(0, 0);
this.menuStrip1.Name = "menuStrip1";
this.menuStrip1.RenderMode = System.Windows.Forms.ToolStripRenderMode.System;
this.menuStrip1.Size = new System.Drawing.Size(1050, 24);
this.menuStrip1.TabIndex = 1;
this.menuStrip1.Text = "menuStrip1";
//
// fileToolStripMenuItem
//
this.fileToolStripMenuItem.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] {
this.closeToolStripMenuItem});
this.fileToolStripMenuItem.Name = "fileToolStripMenuItem";
this.fileToolStripMenuItem.Size = new System.Drawing.Size(37, 20);
this.fileToolStripMenuItem.Text = "File";
//
// closeToolStripMenuItem
//
this.closeToolStripMenuItem.BackColor = System.Drawing.Color.Silver;
this.closeToolStripMenuItem.Name = "closeToolStripMenuItem";
this.closeToolStripMenuItem.Size = new System.Drawing.Size(103, 22);
this.closeToolStripMenuItem.Text = "Close";
this.closeToolStripMenuItem.Click += new System.EventHandler(this.closeToolStripMenuItem_Click);
//
// panel1
//
this.panel1.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(42)))), ((int)(((byte)(42)))), ((int)(((byte)(42)))));
@ -179,85 +116,24 @@
this.label1.Text = "Object Browser";
this.label1.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
//
// label2
// containerProperties
//
this.label2.Dock = System.Windows.Forms.DockStyle.Fill;
this.label2.Font = new System.Drawing.Font("Microsoft Sans Serif", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.label2.ForeColor = System.Drawing.Color.Silver;
this.label2.Location = new System.Drawing.Point(0, 0);
this.label2.Name = "label2";
this.label2.Padding = new System.Windows.Forms.Padding(0, 4, 0, 0);
this.label2.Size = new System.Drawing.Size(238, 27);
this.label2.TabIndex = 0;
this.label2.Text = "Project Explorer";
this.label2.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
this.containerProperties.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
this.containerProperties.Dock = System.Windows.Forms.DockStyle.Fill;
this.containerProperties.Location = new System.Drawing.Point(0, 0);
this.containerProperties.Name = "containerProperties";
//
// panel2
// containerProperties.Panel1
//
this.panel2.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(42)))), ((int)(((byte)(42)))), ((int)(((byte)(42)))));
this.panel2.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
this.panel2.Controls.Add(this.label2);
this.panel2.Dock = System.Windows.Forms.DockStyle.Top;
this.panel2.Location = new System.Drawing.Point(0, 0);
this.panel2.Name = "panel2";
this.panel2.Size = new System.Drawing.Size(240, 29);
this.panel2.TabIndex = 1;
this.containerProperties.Panel1.Controls.Add(this.tabControl1);
this.containerProperties.Panel1.Controls.Add(this.panel4);
//
// label3
// containerProperties.Panel2
//
this.label3.Dock = System.Windows.Forms.DockStyle.Fill;
this.label3.Font = new System.Drawing.Font("Microsoft Sans Serif", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.label3.ForeColor = System.Drawing.Color.Silver;
this.label3.Location = new System.Drawing.Point(0, 0);
this.label3.Name = "label3";
this.label3.Padding = new System.Windows.Forms.Padding(0, 4, 0, 0);
this.label3.Size = new System.Drawing.Size(238, 27);
this.label3.TabIndex = 0;
this.label3.Text = "Object Properties";
this.label3.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
//
// panel3
//
this.panel3.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(42)))), ((int)(((byte)(42)))), ((int)(((byte)(42)))));
this.panel3.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
this.panel3.Controls.Add(this.label3);
this.panel3.Dock = System.Windows.Forms.DockStyle.Top;
this.panel3.Location = new System.Drawing.Point(0, 0);
this.panel3.Name = "panel3";
this.panel3.Size = new System.Drawing.Size(240, 29);
this.panel3.TabIndex = 1;
//
// label4
//
this.label4.Dock = System.Windows.Forms.DockStyle.Fill;
this.label4.Font = new System.Drawing.Font("Microsoft Sans Serif", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.label4.ForeColor = System.Drawing.Color.Silver;
this.label4.Location = new System.Drawing.Point(0, 0);
this.label4.Name = "label4";
this.label4.Padding = new System.Windows.Forms.Padding(0, 4, 0, 0);
this.label4.Size = new System.Drawing.Size(663, 27);
this.label4.TabIndex = 0;
this.label4.Text = "Visual Designer";
this.label4.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
//
// panel4
//
this.panel4.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(42)))), ((int)(((byte)(42)))), ((int)(((byte)(42)))));
this.panel4.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
this.panel4.Controls.Add(this.label4);
this.panel4.Dock = System.Windows.Forms.DockStyle.Top;
this.panel4.Location = new System.Drawing.Point(0, 0);
this.panel4.Name = "panel4";
this.panel4.Size = new System.Drawing.Size(665, 29);
this.panel4.TabIndex = 1;
//
// flowLayoutPanel1
//
this.flowLayoutPanel1.Dock = System.Windows.Forms.DockStyle.Fill;
this.flowLayoutPanel1.Location = new System.Drawing.Point(0, 29);
this.flowLayoutPanel1.Name = "flowLayoutPanel1";
this.flowLayoutPanel1.Size = new System.Drawing.Size(131, 558);
this.flowLayoutPanel1.TabIndex = 1;
this.containerProperties.Panel2.Controls.Add(this.containerLeftPane);
this.containerProperties.Size = new System.Drawing.Size(913, 589);
this.containerProperties.SplitterDistance = 667;
this.containerProperties.TabIndex = 0;
//
// tabControl1
//
@ -284,6 +160,89 @@
this.page1.DragDrop += new System.Windows.Forms.DragEventHandler(this.page1_DragDrop);
this.page1.DragEnter += new System.Windows.Forms.DragEventHandler(this.page1_DragEnter);
//
// panel4
//
this.panel4.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(42)))), ((int)(((byte)(42)))), ((int)(((byte)(42)))));
this.panel4.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
this.panel4.Controls.Add(this.label4);
this.panel4.Dock = System.Windows.Forms.DockStyle.Top;
this.panel4.Location = new System.Drawing.Point(0, 0);
this.panel4.Name = "panel4";
this.panel4.Size = new System.Drawing.Size(665, 29);
this.panel4.TabIndex = 1;
//
// label4
//
this.label4.Dock = System.Windows.Forms.DockStyle.Fill;
this.label4.Font = new System.Drawing.Font("Microsoft Sans Serif", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.label4.ForeColor = System.Drawing.Color.Silver;
this.label4.Location = new System.Drawing.Point(0, 0);
this.label4.Name = "label4";
this.label4.Padding = new System.Windows.Forms.Padding(0, 4, 0, 0);
this.label4.Size = new System.Drawing.Size(663, 27);
this.label4.TabIndex = 0;
this.label4.Text = "Visual Designer";
this.label4.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
//
// containerLeftPane
//
this.containerLeftPane.Dock = System.Windows.Forms.DockStyle.Fill;
this.containerLeftPane.Location = new System.Drawing.Point(0, 0);
this.containerLeftPane.Name = "containerLeftPane";
this.containerLeftPane.Orientation = System.Windows.Forms.Orientation.Horizontal;
//
// containerLeftPane.Panel1
//
this.containerLeftPane.Panel1.Controls.Add(this.treeProjectExplorer);
this.containerLeftPane.Panel1.Controls.Add(this.panel2);
//
// containerLeftPane.Panel2
//
this.containerLeftPane.Panel2.Controls.Add(this.propertyGrid1);
this.containerLeftPane.Panel2.Controls.Add(this.panel3);
this.containerLeftPane.Size = new System.Drawing.Size(240, 587);
this.containerLeftPane.SplitterDistance = 297;
this.containerLeftPane.TabIndex = 0;
//
// treeProjectExplorer
//
this.treeProjectExplorer.BackColor = System.Drawing.Color.Gray;
this.treeProjectExplorer.Dock = System.Windows.Forms.DockStyle.Fill;
this.treeProjectExplorer.Location = new System.Drawing.Point(0, 29);
this.treeProjectExplorer.Name = "treeProjectExplorer";
treeNode11.Name = "nodeGameObjects";
treeNode11.Text = "Game Objects";
treeNode12.Name = "nodeGame";
treeNode12.Text = "Game";
this.treeProjectExplorer.Nodes.AddRange(new System.Windows.Forms.TreeNode[] {
treeNode12});
this.treeProjectExplorer.Size = new System.Drawing.Size(240, 268);
this.treeProjectExplorer.TabIndex = 2;
//
// panel2
//
this.panel2.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(42)))), ((int)(((byte)(42)))), ((int)(((byte)(42)))));
this.panel2.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
this.panel2.Controls.Add(this.label2);
this.panel2.Dock = System.Windows.Forms.DockStyle.Top;
this.panel2.Location = new System.Drawing.Point(0, 0);
this.panel2.Name = "panel2";
this.panel2.Size = new System.Drawing.Size(240, 29);
this.panel2.TabIndex = 1;
//
// label2
//
this.label2.Dock = System.Windows.Forms.DockStyle.Fill;
this.label2.Font = new System.Drawing.Font("Microsoft Sans Serif", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.label2.ForeColor = System.Drawing.Color.Silver;
this.label2.Location = new System.Drawing.Point(0, 0);
this.label2.Name = "label2";
this.label2.Padding = new System.Windows.Forms.Padding(0, 4, 0, 0);
this.label2.Size = new System.Drawing.Size(238, 27);
this.label2.TabIndex = 0;
this.label2.Text = "Project Explorer";
this.label2.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
//
// propertyGrid1
//
this.propertyGrid1.Dock = System.Windows.Forms.DockStyle.Fill;
@ -292,20 +251,93 @@
this.propertyGrid1.Size = new System.Drawing.Size(240, 257);
this.propertyGrid1.TabIndex = 2;
//
// treeProjectExplorer
// panel3
//
this.treeProjectExplorer.BackColor = System.Drawing.Color.Gray;
this.treeProjectExplorer.Dock = System.Windows.Forms.DockStyle.Fill;
this.treeProjectExplorer.Location = new System.Drawing.Point(0, 29);
this.treeProjectExplorer.Name = "treeProjectExplorer";
treeNode3.Name = "nodeGameObjects";
treeNode3.Text = "Game Objects";
treeNode4.Name = "nodeGame";
treeNode4.Text = "Game";
this.treeProjectExplorer.Nodes.AddRange(new System.Windows.Forms.TreeNode[] {
treeNode4});
this.treeProjectExplorer.Size = new System.Drawing.Size(240, 268);
this.treeProjectExplorer.TabIndex = 2;
this.panel3.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(42)))), ((int)(((byte)(42)))), ((int)(((byte)(42)))));
this.panel3.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
this.panel3.Controls.Add(this.label3);
this.panel3.Dock = System.Windows.Forms.DockStyle.Top;
this.panel3.Location = new System.Drawing.Point(0, 0);
this.panel3.Name = "panel3";
this.panel3.Size = new System.Drawing.Size(240, 29);
this.panel3.TabIndex = 1;
//
// label3
//
this.label3.Dock = System.Windows.Forms.DockStyle.Fill;
this.label3.Font = new System.Drawing.Font("Microsoft Sans Serif", 9.75F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.label3.ForeColor = System.Drawing.Color.Silver;
this.label3.Location = new System.Drawing.Point(0, 0);
this.label3.Name = "label3";
this.label3.Padding = new System.Windows.Forms.Padding(0, 4, 0, 0);
this.label3.Size = new System.Drawing.Size(238, 27);
this.label3.TabIndex = 0;
this.label3.Text = "Object Properties";
this.label3.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
//
// menuStrip1
//
this.menuStrip1.BackColor = System.Drawing.Color.Silver;
this.menuStrip1.Items.AddRange(new System.Windows.Forms.ToolStripItem[] {
this.fileToolStripMenuItem,
this.projectToolStripMenuItem});
this.menuStrip1.Location = new System.Drawing.Point(0, 0);
this.menuStrip1.Name = "menuStrip1";
this.menuStrip1.RenderMode = System.Windows.Forms.ToolStripRenderMode.System;
this.menuStrip1.Size = new System.Drawing.Size(1050, 24);
this.menuStrip1.TabIndex = 1;
this.menuStrip1.Text = "menuStrip1";
//
// fileToolStripMenuItem
//
this.fileToolStripMenuItem.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] {
this.closeToolStripMenuItem});
this.fileToolStripMenuItem.Name = "fileToolStripMenuItem";
this.fileToolStripMenuItem.Size = new System.Drawing.Size(37, 20);
this.fileToolStripMenuItem.Text = "File";
//
// closeToolStripMenuItem
//
this.closeToolStripMenuItem.BackColor = System.Drawing.Color.Silver;
this.closeToolStripMenuItem.Name = "closeToolStripMenuItem";
this.closeToolStripMenuItem.Size = new System.Drawing.Size(103, 22);
this.closeToolStripMenuItem.Text = "Close";
this.closeToolStripMenuItem.Click += new System.EventHandler(this.closeToolStripMenuItem_Click);
//
// projectToolStripMenuItem
//
this.projectToolStripMenuItem.DropDownItems.AddRange(new System.Windows.Forms.ToolStripItem[] {
this.createNewObjectToolStripMenuItem,
this.toolStripMenuItem1,
this.refreshObjectBrowserToolStripMenuItem});
this.projectToolStripMenuItem.Name = "projectToolStripMenuItem";
this.projectToolStripMenuItem.Size = new System.Drawing.Size(59, 20);
this.projectToolStripMenuItem.Text = "Objects";
//
// createNewObjectToolStripMenuItem
//
this.createNewObjectToolStripMenuItem.Name = "createNewObjectToolStripMenuItem";
this.createNewObjectToolStripMenuItem.Size = new System.Drawing.Size(196, 22);
this.createNewObjectToolStripMenuItem.Text = "Managed Objects";
//
// toolStripMenuItem1
//
this.toolStripMenuItem1.Name = "toolStripMenuItem1";
this.toolStripMenuItem1.Size = new System.Drawing.Size(193, 6);
//
// refreshObjectBrowserToolStripMenuItem
//
this.refreshObjectBrowserToolStripMenuItem.Name = "refreshObjectBrowserToolStripMenuItem";
this.refreshObjectBrowserToolStripMenuItem.Size = new System.Drawing.Size(196, 22);
this.refreshObjectBrowserToolStripMenuItem.Text = "Refresh Object Browser";
//
// flowLayoutPanel1
//
this.flowLayoutPanel1.Dock = System.Windows.Forms.DockStyle.Fill;
this.flowLayoutPanel1.Location = new System.Drawing.Point(0, 29);
this.flowLayoutPanel1.Name = "flowLayoutPanel1";
this.flowLayoutPanel1.Size = new System.Drawing.Size(131, 558);
this.flowLayoutPanel1.TabIndex = 2;
//
// frmMain
//
@ -323,19 +355,19 @@
this.containerMain.Panel1.ResumeLayout(false);
this.containerMain.Panel2.ResumeLayout(false);
this.containerMain.ResumeLayout(false);
this.panel1.ResumeLayout(false);
this.containerProperties.Panel1.ResumeLayout(false);
this.containerProperties.Panel2.ResumeLayout(false);
this.containerProperties.ResumeLayout(false);
this.tabControl1.ResumeLayout(false);
this.panel4.ResumeLayout(false);
this.containerLeftPane.Panel1.ResumeLayout(false);
this.containerLeftPane.Panel2.ResumeLayout(false);
this.containerLeftPane.ResumeLayout(false);
this.menuStrip1.ResumeLayout(false);
this.menuStrip1.PerformLayout();
this.panel1.ResumeLayout(false);
this.panel2.ResumeLayout(false);
this.panel3.ResumeLayout(false);
this.panel4.ResumeLayout(false);
this.tabControl1.ResumeLayout(false);
this.menuStrip1.ResumeLayout(false);
this.menuStrip1.PerformLayout();
this.ResumeLayout(false);
this.PerformLayout();
@ -357,11 +389,15 @@
private System.Windows.Forms.Label label2;
private System.Windows.Forms.Panel panel3;
private System.Windows.Forms.Label label3;
private System.Windows.Forms.FlowLayoutPanel flowLayoutPanel1;
private System.Windows.Forms.TabControl tabControl1;
private System.Windows.Forms.TabPage page1;
private System.Windows.Forms.PropertyGrid propertyGrid1;
private System.Windows.Forms.TreeView treeProjectExplorer;
private System.Windows.Forms.ToolStripMenuItem projectToolStripMenuItem;
private System.Windows.Forms.ToolStripMenuItem createNewObjectToolStripMenuItem;
private System.Windows.Forms.ToolStripSeparator toolStripMenuItem1;
private System.Windows.Forms.ToolStripMenuItem refreshObjectBrowserToolStripMenuItem;
private System.Windows.Forms.FlowLayoutPanel flowLayoutPanel1;
}
}

View file

@ -138,6 +138,11 @@ namespace VisualDesigner
if (page1.Text == "Empty")
{
page1.Text = currentScript.Name;
if (currentScript.Name == "Room")
{
page1.Controls.Add(new VisualComponents.RoomDesigner((Room)currentScript.Instance));
}
break;
}
//Otherwise create a new page
else
@ -148,9 +153,11 @@ namespace VisualDesigner
tab.DragEnter += new DragEventHandler(page1_DragEnter);
tab.AllowDrop = true;
tab.BackColor = Color.FromArgb(64,64,64);
page1.Text = currentScript.Name;
tabControl1.TabPages.Add(tab);
//select the tab.
tabControl1.SelectedTab = tab;
break;
}
}
}