private void timer_Elapsed(object state)
private
{
if (_synchronizeEvent && Dispatcher.CurrentDispatcher != _dispatcher)
//_dispatcher is a reference to the Dispatcher under wich the timer was instantiated
_dispatcher.Invoke(
new System.Threading.ThreadStart(delegate
onTick();
}),
}
private void onTick(){if (Tick != null){Tick(this, new EventArgs());}}
_dispatcher.Thread