public void StopListening()
 {
     if (_isXinput)
     {
         _joystickControlXInput?.StopListening();
     }
     else
     {
         _joystickControlDirectInput?.StopListening();
     }
 }
 public void StopListening()
 {
     if (_inputApi == InputApi.DirectInput)
     {
         _joystickControlDirectInput?.StopListening();
     }
     else if (_inputApi == InputApi.XInput)
     {
         _joystickControlXInput?.StopListening();
     }
     else if (_inputApi == InputApi.RawInput)
     {
         _joystickControlRawInput?.StopListening();
     }
 }