本文整理匯總了C#中System.Windows.Forms.ToolStrip.GetNextItem方法的典型用法代碼示例。如果您正苦於以下問題:C# ToolStrip.GetNextItem方法的具體用法?C# ToolStrip.GetNextItem怎麽用?C# ToolStrip.GetNextItem使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類System.Windows.Forms.ToolStrip
的用法示例。
在下文中一共展示了ToolStrip.GetNextItem方法的3個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的C#代碼示例。
示例1: MethodGetNextItemIEAE
public void MethodGetNextItemIEAE ()
{
ToolStrip ts = new ToolStrip ();
ts.GetNextItem (null, (ArrowDirection)42);
}
示例2: GetNextItem
private ToolStripItem GetNextItem(ToolStrip parent, ToolStripItem startItem, ArrowDirection direction)
{
if ((parent.RightToLeft == RightToLeft.Yes) && ((direction == ArrowDirection.Left) || (direction == ArrowDirection.Right)))
{
if (direction == ArrowDirection.Right)
{
direction = ArrowDirection.Left;
}
else if (direction == ArrowDirection.Left)
{
direction = ArrowDirection.Right;
}
}
return parent.GetNextItem(startItem, direction);
}
示例3: MethodGetNextItem
public void MethodGetNextItem ()
{
ToolStrip ts = new ToolStrip ();
ts.Items.Add ("Test Item 1");
Form f = new Form ();
f.ShowInTaskbar = false;
f.Controls.Add (ts);
f.Show ();
Assert.AreEqual (ts.Items[0], ts.GetNextItem (null, ArrowDirection.Right), "A1");
Assert.AreEqual (ts.Items[0], ts.GetNextItem (ts.Items[0], ArrowDirection.Right), "A2");
ts.Items.Add ("Test Item 2");
Assert.AreEqual (ts.Items[0], ts.GetNextItem (null, ArrowDirection.Right), "A3");
Assert.AreEqual (ts.Items[1], ts.GetNextItem (ts.Items[0], ArrowDirection.Right), "A4");
f.Dispose ();
}