public FwLcmUI(IHelpTopicProvider helpTopicProvider, ISynchronizeInvoke synchronizeInvoke) { m_helpTopicProvider = helpTopicProvider; m_synchronizeInvoke = synchronizeInvoke; m_activityMonitor = new UserActivityMonitor(); m_activityMonitor.StartMonitoring(); }
public IdleStatusChanger(IChatClient chatClient, TimeSpan timeout) { this.client = chatClient; this.monitor = new UserActivityMonitor(timeout); monitor.Idle += (sender, e) => { if (client.IsLoggedIn && client.CurrentUser.Status.In(UserStatus.Online, UserStatus.Busy)) { lastStatus = client.CurrentUser.Status; client.CurrentUser.Status = UserStatus.Idle; } }; monitor.Active += (sender, e) => { if (client.IsLoggedIn && lastStatus.HasValue) { client.CurrentUser.Status = lastStatus.Value; } lastStatus = null; }; monitor.Start(); }
public ParatextLexiconPluginFdoUI(ActivationContextHelper activationContext) { m_synchronizeInvoke = new SynchronizeInvokeWrapper(activationContext); m_activityMonitor = new UserActivityMonitor(); m_activityMonitor.StartMonitoring(); }
public ParatextLexiconPluginLcmUI() { m_activityMonitor = new UserActivityMonitor(); m_activityMonitor.StartMonitoring(); }