コード例 #1
0
        private void client_UserModeIsReply( object sender, IrcMessageEventArgs<UserModeIsReplyMessage> e )
        {
            Client source = sender as Client;
            if ( source == null )
            {
                return;
            }

            if ( IsMe( e.Message.Target, source ) )
            {
                UserModesCreator modeCreator = new UserModesCreator();
                modeCreator.Parse( e.Message.Modes );
                source.User.Modes.Clear();
                foreach ( UserMode mode in modeCreator.Modes )
                {
                    source.User.Modes.Add( mode );
                }
            }
        }
コード例 #2
0
 private void client_UserModeIsReply( object sender, IrcMessageEventArgs<UserModeIsReplyMessage> e )
 {
     if ( IsMe( e.Message.Target ) )
     {
         UserModesCreator modeCreator = new UserModesCreator();
         modeCreator.Parse( e.Message.Modes );
         this.User.Modes.Clear();
         foreach ( UserMode mode in modeCreator.Modes )
         {
             this.User.Modes.Add( mode );
         }
     }
 }