static AccountViewModel() { tickCall = new Timer( _ => TimeTickCall.Raise(EventArgs.Empty), null, 0, 20 * 1000); ThreadHelper.Halt += () => tickCall.Dispose(); }
protected void OnConnectionStateChanged(EventArgs e) { var threadSafeHandler = Interlocked.CompareExchange(ref ConnectionStateChanged, null, null); if (threadSafeHandler != null) { threadSafeHandler(this, e); } ConnectionStateChangedEvent.Raise(e); }
private static void OnWakeupTimeUpdated(EventArgs e) { var threadSafeHandler = Interlocked.CompareExchange(ref WakeupTimeUpdated, null, null); if (threadSafeHandler != null) { threadSafeHandler(null, e); } WakeupTimeUpdatedEvent.Raise(e); }
private static void OnTweetSpeedUpdated(EventArgs e) { var threadSafeHandler = Interlocked.CompareExchange(ref TweetSpeedUpdated, null, null); if (threadSafeHandler != null) { threadSafeHandler(null, e); } TweetSpeedUpdatedEvent.Raise(e); }
private static void OnNotifyTextChanged(NotifyUpdatedEventArgs e) { var threadSafeHandler = Interlocked.CompareExchange(ref NotifyTextChanged, null, null); if (threadSafeHandler != null) { threadSafeHandler(null, e); } NotifyTextChangedEvent.Raise(e); }
protected void OnRequireClose(NotifierViewModelEventArgs e) { var threadSafeHandler = Interlocked.CompareExchange(ref RequireClose, null, null); if (threadSafeHandler != null) { threadSafeHandler(this, e); } RequireCloseEvent.Raise(e); }
protected virtual void OnFileDrop(FileDropEventArgs e) { var threadSafeHandler = Interlocked.CompareExchange(ref FileDrop, null, null); if (threadSafeHandler != null) { threadSafeHandler(this, e); } FileDropEvent.Raise(e); }
protected void OnItemsOpening(EventArgs e) { var threadSafeHandler = Interlocked.CompareExchange(ref ItemsOpening, null, null); if (threadSafeHandler != null) { threadSafeHandler(this, e); } ItemsOpeningEvent.Raise(e); }
protected void OnLinkAccountInfoChanged(EventArgs e) { var threadSafeHandler = Interlocked.CompareExchange(ref LinkAccountInfoChanged, null, null); if (threadSafeHandler != null) { threadSafeHandler(this, e); } LinkAccountInfoChangedEvent.Raise(e); }
private static void OnOnUnderControlChanged(UnderControlEventArgs e) { var threadSafeHandler = Interlocked.CompareExchange(ref OnUnderControlChanged, null, null); if (threadSafeHandler != null) { threadSafeHandler(null, e); } OnUnderControlChangedEvent.Raise(e); }
private static void OnSettingValueChanged(EventArgs e) { var threadSafeHandler = Interlocked.CompareExchange(ref SettingValueChanged, null, null); if (threadSafeHandler != null) { threadSafeHandler(null, e); } SettingValueChangedEvent.Raise(e); }
private static void OnEventRegistered(EventDescriptionEventArgs e) { var threadSafeHandler = Interlocked.CompareExchange(ref EventRegistered, null, null); if (threadSafeHandler != null) { threadSafeHandler(null, e); } EventRegisteredEvent.Raise(e); }