private void event_handler(FreeSWITCH.EventBinding.EventBindingArgs args) {
if (Application.Current == null)//can happen during shutdown
return;
if (BroadcastHandler == null)
BroadcastHandler = new BroadcastEventDel(BroadcastEvent);
Application.Current.Dispatcher.BeginInvoke(BroadcastHandler, new object[] { new FSEvent(args.EventObj) });
}