本文整理汇总了C#中Button.MakeClick方法的典型用法代码示例。如果您正苦于以下问题:C# Button.MakeClick方法的具体用法?C# Button.MakeClick怎么用?C# Button.MakeClick使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Button
的用法示例。
在下文中一共展示了Button.MakeClick方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: BreakpointInsideOneLineDelegate
public void BreakpointInsideOneLineDelegate ()
{
var button = new Button ();
int numClicks = 0;
button.Clicked += (object sender, EventArgs e) => button.SetTitle (String.Format ("clicked {0} times", numClicks++));/*22af08d6-dafc-47f1-b8d1-bee1526840fd*/
button.MakeClick ();/*67ae4cce-22b3-49d8-8221-7e5b26a5e79b*/
}
示例2: BreakpointInsideOneLineDelegateAsync
public void BreakpointInsideOneLineDelegateAsync ()
{
var button = new Button ();
int numClicks = 0;
button.Clicked += async (sender, e) => button.SetTitle (String.Format ("clicked {0} times", numClicks++));/*b6a65e9e-5db2-4850-969a-b3747b2459af*/
button.MakeClick ();
}
示例3: BreakpointInsideOneLineDelegateNoDisplayClass
public static void BreakpointInsideOneLineDelegateNoDisplayClass ()
{
var button = new Button ();
button.Clicked += (sender, e) => Console.WriteLine (); /*e72a2fa6-2d95-4f96-b3d0-ba321da3cb55*/
button.MakeClick ();/*e0a96c37-577f-43e3-9a20-2cdd8bf7824e*/
}