vibration property

GamepadVibration get vibration

Implementation

GamepadVibration get vibration {
  final retValuePtr = calloc<GamepadVibration>();

  try {
    final hr = ptr.ref.vtable
        .elementAt(6)
        .cast<
            Pointer<
                NativeFunction<
                    HRESULT Function(Pointer, Pointer<GamepadVibration>)>>>()
        .value
        .asFunction<
            int Function(Pointer,
                Pointer<GamepadVibration>)>()(ptr.ref.lpVtbl, retValuePtr);

    if (FAILED(hr)) throw WindowsException(hr);

    final retValue = retValuePtr.ref;
    return retValue;
  } finally {}
}
set vibration (GamepadVibration value)

Implementation

set vibration(GamepadVibration value) {
  final hr = ptr.ref.vtable
      .elementAt(7)
      .cast<
          Pointer<
              NativeFunction<HRESULT Function(Pointer, GamepadVibration)>>>()
      .value
      .asFunction<
          int Function(Pointer, GamepadVibration)>()(ptr.ref.lpVtbl, value);

  if (FAILED(hr)) throw WindowsException(hr);
}