示例#1
0
        private void OnMouseInputEvent(SDL.SDL_MouseButtonEvent e)
        {
            MouseButton button = ConvertMouseButton(e.button);

            if (e.type == SDL.SDL_EventType.SDL_MOUSEBUTTONDOWN)
            {
                MouseState.HandleButtonDown(button);
            }
            else
            {
                MouseState.HandleButtonUp(button);
            }
        }
示例#2
0
        private void OnMouseInputEvent(Silk.NET.SDL.MouseButtonEvent e)
        {
            MouseButton button = ConvertMouseButton(e.Button);

            if ((EventType)e.Type == EventType.Mousebuttondown)
            {
                MouseState.HandleButtonDown(button);
            }
            else
            {
                MouseState.HandleButtonUp(button);
            }
        }
示例#3
0
 private void OnMouseDown(object sender, MouseEventArgs mouseEventArgs)
 {
     uiControl.Focus();
     MouseState.HandleButtonDown(ConvertMouseButton(mouseEventArgs.Button));
 }