Beispiel #1
0
        public ChangeStringDialog(StringBlock block, Int32 maxLength)
        {
            if (block == null)
            {
                throw new ArgumentNullException("block");
            }

            this.block     = block;
            this.maxLength = maxLength;

            InitializeComponent();

            valueTextBox.MaxLength = maxLength;

            valueTextBox.Text = block.Value;

            valueTextBox.KeyDown += new KeyEventHandler(HitEnterKey);
        }
Beispiel #2
0
		/// <summary>
		/// Gets whether a given Moveable represents a string value or variable.
		/// </summary>
		/// <param name="moveable">The Moveable to check.</param>
		/// <returns>True if the Moveable is a string; false otherwise.</returns>
		public static bool IsString(Moveable moveable)
		{
			StringBlock stringBlock = moveable as StringBlock;
			return stringBlock != null;
		}
Beispiel #3
0
 public bool Equals(StringBlock other)
 {
     return(other != null && other.Value == Value);
 }
Beispiel #4
0
 public ChangeStringDialog(StringBlock block) : this(block, 140)
 {
 }