Store name in OKSKeyboardController to avoid setting it in detector

This commit is contained in:
Adam Honse
2025-08-14 19:06:29 -05:00
parent e418aa7f95
commit 2c630a5218
4 changed files with 54 additions and 47 deletions

View File

@@ -13,10 +13,11 @@
#include "OKSKeyboardController.h"
#include "StringUtils.h"
OKSKeyboardController::OKSKeyboardController(hid_device* dev_handle, const char* path, const unsigned short pid)
OKSKeyboardController::OKSKeyboardController(hid_device* dev_handle, const char* path, const unsigned short pid, std::string dev_name)
{
dev = dev_handle;
location = path;
name = dev_name;
usb_pid = pid;
SendInitialize();
@@ -32,6 +33,11 @@ std::string OKSKeyboardController::GetDeviceLocation()
return("HID: " + location);
}
std::string OKSKeyboardController::GetNameString()
{
return(name);
}
std::string OKSKeyboardController::GetSerialString()
{
wchar_t serial_string[128];