WPF属性触发器播放音乐EnterActions ExitActions

属性触发器除了定义Setters 之外,还可以定义EnterActions 和ExitActions。使用这两个属性,可以定义一个
TriggerAction 元素集合。EnterActions 在启动触发器时激活(此时通过属性触发器应用Property/Value
组合)。ExitActions 在触发器结束之前激活(此时不再应用Property/Value 组合)。用这些操作指定的触
发器操作派生自基类TriggerAction,如SoundPlayerAction 和BeginStoryboard。使用SoundPlayerAction
基类可以开始播放声音,BeginStoryboard 基类用于动画

posted @ 2018-03-23 17:13  LILIEHN  阅读(269)  评论(0编辑  收藏  举报