Skip to content

Implement GetDevice method to retrieve a device by its ID#22

Open
dikkadev wants to merge 1 commit into
moutend:developfrom
dikkadev:implement-getdevice
Open

Implement GetDevice method to retrieve a device by its ID#22
dikkadev wants to merge 1 commit into
moutend:developfrom
dikkadev:implement-getdevice

Conversation

@dikkadev

Copy link
Copy Markdown

No description provided.

* **pkg/wca/IMMDeviceEnumerator.go**
  - Implement `GetDevice` method to retrieve a device by its ID using `mmdeGetDevice`.

* **pkg/wca/IMMDeviceEnumerator_windows.go**
  - Implement `mmdeGetDevice` function to retrieve a device by its ID.
  - Use `syscall.Syscall` to call the `GetDevice` method.
  - Handle the HRESULT return value and convert it to an error if needed.

* **pkg/wca/IMMDeviceEnumerator_func.go**
  - Implement `mmdeGetDevice` function to retrieve a device by its ID.
  - Return `ole.NewError(ole.E_NOTIMPL)` for non-Windows builds.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant