10 references to IndexOf
System.Windows.Forms (5)
System\Windows\Forms\Controls\TabControl\TabControl.TabPageCollection.cs (3)
96return IndexOf(tabPage); 138return IndexOf(page) != -1; 181return IndexOf(tabPage);
System\Windows\Forms\Controls\TabControl\TabPage.cs (1)
167int currentIndex = tabControl.TabPages.IndexOf(this);
System\Windows\Forms\Controls\TabControl\TabPage.TabAccessibleObject.cs (1)
76private int CurrentIndex => OwningTabControl?.TabPages.IndexOf(_owningTabPage) ?? -1;
System.Windows.Forms.Tests (5)
System\Windows\Forms\TabControl.TabPageCollectionTests.cs (5)
1858Assert.Equal(0, collection.IndexOf(child1)); 1859Assert.Equal(1, collection.IndexOf(child2)); 1860Assert.Equal(-1, collection.IndexOf(new TabPage())); 1868Assert.Equal(-1, collection.IndexOf(new TabPage())); 1876Assert.Throws<ArgumentNullException>("page", () => collection.IndexOf(null));