Example #1
0
        private void UsersReceivedUserList(object sender, ReceivedListEventArgs <IUserInfo> e)
        {
            this.users.Update(this.gablarski.Channels, e.Data, this.gablarski.Sources);

            if (this.speech != null)
            {
                this.speech.Update(this.gablarski.Channels, this.gablarski.Users);
            }

            lock (this.ignores)
            {
                if (this.ignores == null)
                {
                    return;
                }

                var usernames = this.gablarski.Users.ToDictionary(u => u.Username.Replace(" ", String.Empty).ToLower());
                foreach (string username in this.ignores.ToList())
                {
                    IUserInfo user;
                    if (!usernames.TryGetValue(username, out user) || this.gablarski.Users.GetIsIgnored(user))
                    {
                        continue;
                    }

                    this.gablarski.Users.ToggleIgnore(user);
                    usernames.Remove(username);
                }
            }
        }
Example #2
0
 void SourcesRemoved(object sender, ReceivedListEventArgs <AudioSource> e)
 {
     foreach (var s in e.Data)
     {
         this.gablarski.Audio.Detach(s);
     }
 }
Example #3
0
        private void ChannelsReceivedChannelList(object sender, ReceivedListEventArgs <IChannelInfo> e)
        {
            this.users.Update(e.Data, this.gablarski.Users, this.gablarski.Sources);

            if (this.speech != null)
            {
                this.speech.Update(this.gablarski.Channels, this.gablarski.Users);
            }
        }
Example #4
0
 protected virtual void OnSourcesRemoved(ReceivedListEventArgs<AudioSource> e)
 {
     var removed = this.AudioSourcesRemoved;
     if (removed != null)
         removed (this, e);
 }
Example #5
0
 protected virtual void OnReceivedSourceList(ReceivedListEventArgs<AudioSource> e)
 {
     var received = this.ReceivedSourceList;
     if (received != null)
         received (this, e);
 }
Example #6
0
		private void ChannelsReceivedChannelList (object sender, ReceivedListEventArgs<IChannelInfo> e)
		{
			this.users.Update (e.Data, this.gablarski.Users, this.gablarski.Sources);

			if (this.speech != null)
				this.speech.Update (this.gablarski.Channels, this.gablarski.Users);
		}
Example #7
0
		private void UsersReceivedUserList (object sender, ReceivedListEventArgs<IUserInfo> e)
		{
			this.users.Update (this.gablarski.Channels, e.Data, this.gablarski.Sources);
			
			if (this.speech != null)
				this.speech.Update (this.gablarski.Channels, this.gablarski.Users);

			lock (this.ignores)
			{
				if (this.ignores == null)
					return;

				var usernames = this.gablarski.Users.ToDictionary (u => u.Username.Replace (" ", String.Empty).ToLower());
				foreach (string username in this.ignores.ToList())
				{
					IUserInfo user;
					if (!usernames.TryGetValue (username, out user) || this.gablarski.Users.GetIsIgnored (user))
						continue;

					this.gablarski.Users.ToggleIgnore (user);
					usernames.Remove (username);
				}
			}
		}
Example #8
0
		void SourcesRemoved (object sender, ReceivedListEventArgs<AudioSource> e)
		{
			foreach (var s in e.Data)
				this.gablarski.Audio.Detach (s);
		}
Example #9
0
		private void SourcesOnReceivedSourceList (object sender, ReceivedListEventArgs<AudioSource> args)
		{
			SetupPlayback();
		}
Example #10
0
 private void SourcesOnReceivedSourceList(object sender, ReceivedListEventArgs <AudioSource> args)
 {
     SetupPlayback();
 }
Example #11
0
 protected virtual void OnReceivedUserList(ReceivedListEventArgs<IUserInfo> e)
 {
     var received = this.ReceivedUserList;
     if (received != null)
         received (this, e);
 }