protected override bool HandleStateRaw(SlackState slackState)
        {
            _lastSlackState = slackState;
            _lastTrayState = slackState.TrayState;

            // Start the animation if possible and enabled
            var canAnimateIcon = SlackWindowsTray.Default.ToBlinkOnMention&& _lastTrayState == TrayStates.ImportantUnread;
            canAnimateIcon |= SlackWindowsTray.Default.ToBlinkOnUnread && _lastTrayState == TrayStates.Unread;
                                 
            _animationTimer.Enabled = canAnimateIcon;

            return true;
        }
示例#2
0
        protected override bool HandleStateRaw(SlackState slackState)
        {
            _lastSlackState = slackState;
            _lastTrayState  = slackState.TrayState;

            // Start the animation if possible and enabled
            var canAnimateIcon = SlackWindowsTray.Default.ToBlinkOnMention && _lastTrayState == TrayStates.ImportantUnread;

            canAnimateIcon |= SlackWindowsTray.Default.ToBlinkOnUnread && _lastTrayState == TrayStates.Unread;

            _animationTimer.Enabled = canAnimateIcon;

            return(true);
        }
 public SlackState(TrayStates trayState)
 {
     _chatStates = new List <ChatState>();
     TrayState   = trayState;
 }
 public SlackState(TrayStates trayState)
 {
     _chatStates = new List<ChatState>();
     TrayState = trayState;
 }
示例#5
0
 public void SetState(TrayStates state)
 {
     targetState = state;
 }