Exemplo n.º 1
0
        /// <summary>
        ///     Gets a textual representation of this object.
        /// </summary>
        /// <returns>a String containing a textual representation of this object.</returns>
        public override string ToString()
        {
            var sb = new StringBuilder();

            sb.Append(GetType().FullName ?? "null");
            sb.Append(":DirectInputDevice:");
            sb.Append(DirectInputDevice?.ToString() ?? "null");
            sb.Append(":DirectInputControl:");
            sb.Append(DirectInputControl?.ToString() ?? "null");
            sb.Append(":Keys:");
            sb.Append(Enum.GetName(typeof(Keys), Keys));
            sb.Append(":ControlType:");
            sb.Append(Enum.GetName(typeof(ControlType), ControlType));
            sb.Append(":PovDirection:");
            sb.Append(Enum.GetName(typeof(PovDirections), PovDirection));
            return(sb.ToString());
        }
Exemplo n.º 2
0
        /// <summary>
        ///   Gets a textual representation of this object.
        /// </summary>
        /// <returns>a String containing a textual representation of this object.</returns>
        public override string ToString()
        {
            var sb = new StringBuilder();

            sb.Append(GetType().FullName ?? "null");
            sb.Append(":CpdInputControl:");
            sb.Append(Enum.GetName(typeof(CpdInputControls), CpdInputControl));
            sb.Append(":ControlName:");
            sb.Append(ControlName ?? "null");
            sb.Append(":DirectInputDevice:");
            sb.Append(DirectInputDevice != null ? DirectInputDevice.ToString() : "null");
            sb.Append(":DirectInputControl:");
            sb.Append(DirectInputControl != null ? DirectInputControl.ToString() : "null");
            sb.Append(":Keys:");
            sb.Append(Enum.GetName(typeof(Keys), Keys));
            sb.Append(":BindingType:");
            sb.Append(Enum.GetName(typeof(BindingType), BindingType));
            sb.Append(":PovDirection:");
            sb.Append(Enum.GetName(typeof(PovDirections), PovDirection));
            return(sb.ToString());
        }