Exemplo n.º 1
0
        /// <summary>
        /// Unsubscribes from keyboard capture events.
        /// </summary>
        /// <param name="subject">The observer to unsubscribe.</param>
        public void Unsubscribe(IKeyboardObserver subject)
        {
            if (!this.Subjects.Contains(subject))
            {
                return;
            }

            this.Subjects.Remove(subject);
        }
Exemplo n.º 2
0
        /// <summary>
        /// Subscribes to keyboard capture events.
        /// </summary>
        /// <param name="subject">The observer to subscribe.</param>
        public void Subscribe(IKeyboardObserver subject)
        {
            if (this.Subjects.Contains(subject))
            {
                return;
            }

            this.Subjects.Add(subject);
        }