cancel method

void cancel()

Implementation

void cancel() {
  final hr = ptr.ref.vtable
      .elementAt(9)
      .cast<Pointer<NativeFunction<HRESULT Function(VTablePointer lpVtbl)>>>()
      .value
      .asFunction<int Function(VTablePointer lpVtbl)>()(ptr.ref.lpVtbl);

  if (FAILED(hr)) throwWindowsException(hr);
}