Clean up folder structure a bit, move .NET 3rdparty under renderdocui/

This commit is contained in:
baldurk
2015-04-13 12:46:30 +01:00
parent b41b5242d1
commit f06964ea23
104 changed files with 17 additions and 16 deletions
@@ -0,0 +1,47 @@
using System;
using System.Collections.ObjectModel;
using System.Collections.Generic;
using System.Drawing;
using System.Windows.Forms;
namespace WeifenLuo.WinFormsUI.Docking
{
public class DockPaneCollection : ReadOnlyCollection<DockPane>
{
internal DockPaneCollection()
: base(new List<DockPane>())
{
}
internal int Add(DockPane pane)
{
if (Items.Contains(pane))
return Items.IndexOf(pane);
Items.Add(pane);
return Count - 1;
}
internal void AddAt(DockPane pane, int index)
{
if (index < 0 || index > Items.Count - 1)
return;
if (Contains(pane))
return;
Items.Insert(index, pane);
}
internal void Dispose()
{
for (int i=Count - 1; i>=0; i--)
this[i].Close();
}
internal void Remove(DockPane pane)
{
Items.Remove(pane);
}
}
}