
可以的,只搭仔粗余是没什么意义
this.txtDelay_KeyDown(txtDelay, new KeyEventArgs(System.Windows.Input.Keyboard.PrimaryDevice,
PresentationSource.CurrentSources.OfType<知凳汪PresentationSource>().First(),
Environment.TickCount,
Key.A))
// 定义事件属性public static readonly RoutedEvent ClickRoutedEvent = EventManager.RegisterRoutedEvent("Click", RoutingStrategy.Bubble, typeof(ClickEventHandler), typeof(ControlName))
[Description("点击时发生")]
public event ClickEventHandler Click
{
add { AddHandler(ClickRoutedEvent, 雀喊value) }
remove { RemoveHandler(ClickRoutedEvent, value) 培指}
}
void button_Click(object sender, RoutedEventArgs e)
{
顷中野 e.RoutedEvent = ScrollChangedRoutedEvent
e.Source = this
this.RaiseEvent(e)
}
欢迎分享,转载请注明来源:内存溢出
微信扫一扫
支付宝扫一扫
评论列表(0条)