Beispiel #1
0
        public Pointer(IntPtr handle)
            : base(handle)
        {
            // Store a handle to delegates for native use so that we do not lose a reference to them
            _enterListener        = OnEnterListener;
            _leaveListener        = OnLeaveListener;
            _motionListener       = OnMotionListener;
            _buttonListener       = OnButtonListener;
            _axisListener         = OnAxisListener;
            _frameListener        = OnFrameListener;
            _axisSourceListener   = OnAxisSourceListener;
            _axisStopListener     = OnAxisStopListener;
            _axisDiscreteListener = OnAxisDiscreteListener;

            // Tie up to our events Wayland-side
            PointerAddListener(handle, _enterListener, _leaveListener, _motionListener, _buttonListener, _axisListener, _frameListener, _axisSourceListener, _axisStopListener, _axisDiscreteListener);
        }
Beispiel #2
0
 private static extern void PointerAddListener(IntPtr pointer, PointerOnEnterListener enterListener, PointerOnLeaveListener leaveListener, PointerOnMotionListener motionListener, PointerOnButtonListener buttonListener, PointerOnAxisListener axisListener, PointerOnFrameListener frameListener, PointerOnAxisSourceListener axisSourceListener, PointerOnAxisStopListener axisStopListener, PointerOnAxisDiscreteListener axisDiscreteListener);