typingargs.cs

来自「Gibphone is CSharp Program, it can tell 」· CS 代码 · 共 61 行

CS
61
字号
using System;
using System.Collections.Generic;
using System.Text;

namespace GPCore.Args
{
    /// <summary>
    /// The EventArgs for a <see cref="ITyping.onTypingNotification"/> Event.
    /// </summary>
    public class TypingArgs : EventArgs
    {
        private String a;
        /// <summary>
        /// The username that sent the Notification
        /// </summary>
        public String Username
        {
            get { return a; }
        }
        private TypingType t;
        /// <summary>
        /// The TypingType of this notification
        /// </summary>
        public TypingType TypingType
        {
            get { return t; }
            set { t = value; }
        }
        /// <summary>
        /// Creates a new TypingArgs
        /// </summary>
        /// <param name="username">The username that sent the Notification</param>
        /// <param name="t">The TypingType of this notification</param>
        public TypingArgs(String username, TypingType t)
        {
            this.t = t; this.a = username;
        }
    }
    /// <summary>
    /// An enum for specifying what type of Typing Notification is
    /// happening through the <see cref="ITyping"/> Interface.
    /// </summary>
    public enum TypingType
    {
        /// <summary>
        /// When the typing has just started.
        /// </summary>
        TYPING_STARTED,
        /// <summary>
        /// When the typing has stoped and there is nothing in the 
        /// text box.
        /// </summary>
        TYPING_FINISHED,
        /// <summary>
        /// When the typing has stoped and there is still something
        /// written in the text box.
        /// </summary>
        TEXT_TYPED
    }
}

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?