Inheritance: WeifenLuo.WinFormsUI.Docking.DockContent
Exemple #1
0
 public void AddRange(BaseWindow[] uiWindow)
 {
     foreach (Form uW in uiWindow)
     {
         this.List.Add(uW);
     }
 }
 public void IndexingByObjectReturnsTheCorrectObject()
 {
     BaseWindow window1 = new BaseWindow();
     BaseWindow window2 = new BaseWindow();
     _windowList.Add(window1);
     _windowList.Add(window2);
     Assert.That(_windowList[window1], Is.EqualTo(window1));
 }
 public void ItemIsNotInListAfterBeingRemoved()
 {
     BaseWindow window1 = new BaseWindow();
     BaseWindow window2 = new BaseWindow();
     _windowList.Add(window1);
     _windowList.Add(window2);
     _windowList.Remove(window1);
     Assert.That(() => _windowList[window1], Throws.TypeOf<ArgumentOutOfRangeException>());
 }
 public void CountIsReducedAfterItemRemoved()
 {
     BaseWindow window1 = new BaseWindow();
     BaseWindow window2 = new BaseWindow();
     _windowList.Add(window1);
     _windowList.Add(window2);
     _windowList.Remove(window1);
     Assert.That(_windowList.Count, Is.EqualTo(1));
 }
 public void GetWindowFromStringReturnsCorrectObject()
 {
     BaseWindow window1 = new BaseWindow();
     window1.SetFormText("TheWindowWeWant");
     BaseWindow window2 = new BaseWindow();
     window2.SetFormText("WeDontWantThisWindow");
     _windowList.Add(window1);
     _windowList.Add(window2);
     Assert.That(_windowList.FromString("TheWindowWeWant"), Is.EqualTo(window1));
 }
Exemple #6
0
 public void Remove(BaseWindow uiWindow)
 {
     this.List.Remove(uiWindow);
 }
Exemple #7
0
 public void Add(BaseWindow uiWindow)
 {
     this.List.Add(uiWindow);
     //AddHandler uiWindow.FormClosing, AddressOf uiFormClosing
 }
Exemple #8
0
 public void Remove(BaseWindow uiWindow)
 {
     this.List.Remove(uiWindow);
 }
Exemple #9
0
 public void Add(BaseWindow uiWindow)
 {
     this.List.Add(uiWindow);
     //AddHandler uiWindow.FormClosing, AddressOf uiFormClosing
 }
 public void ListIsEmptyAfterLastItemRemoved()
 {
     BaseWindow window1 = new BaseWindow();
     _windowList.Add(window1);
     _windowList.Remove(window1);
     Assert.That(_windowList, Is.Empty);
 }
 public void WindowsAreInListAfterCallingAddRange()
 {
     BaseWindow window1 = new BaseWindow();
     BaseWindow window2 = new BaseWindow();
     BaseWindow window3 = new BaseWindow();
     BaseWindow[] windowArray = new BaseWindow[] {window1, window2, window3};
     _windowList.AddRange(windowArray);
     Assert.That(_windowList, Contains.Item(window1));
     Assert.That(_windowList, Contains.Item(window2));
     Assert.That(_windowList, Contains.Item(window3));
 }
 public void WindowIsInListAfterBeingAdded()
 {
     BaseWindow window = new BaseWindow();
     _windowList.Add(window);
     Assert.That(_windowList, Has.Member(window));
 }
 public void ThrowsExceptionWhenIndexingPastListBounds()
 {
     BaseWindow window1 = new BaseWindow();
     _windowList.Add(window1);
     Assert.That(() => _windowList[100], Throws.TypeOf<ArgumentOutOfRangeException>());
 }
 public void ThrowsExceptionWhenIndexingByObjectFails()
 {
     BaseWindow window1 = new BaseWindow();
     Assert.That(() => _windowList[window1], Throws.TypeOf<ArgumentOutOfRangeException>());
 }