AStarTest.Window1.Window_PreTextInput C# (CSharp) Method

Window_PreTextInput() public method

public Window_PreTextInput ( object sender, System.Windows.Input.TextCompositionEventArgs e ) : void
sender object
e System.Windows.Input.TextCompositionEventArgs
return void
        void Window_PreTextInput(object sender, TextCompositionEventArgs e)
        {
            string text = e.Text;
            Direction dir;

            if (text == ">")
            {
                dir = Direction.Down;
            }
            else if (text == "<")
            {
                dir = Direction.Up;
            }
            else
            {
                return;
            }

            e.Handled = true;
            map.ScreenCenterPos += new DoubleVector3(dir);
        }