diff --git a/Controllers/SinowealthController/SinowealthGMOWController.cpp b/Controllers/SinowealthController/SinowealthGMOWController.cpp index c8b454cc..f80b5ca7 100644 --- a/Controllers/SinowealthController/SinowealthGMOWController.cpp +++ b/Controllers/SinowealthController/SinowealthGMOWController.cpp @@ -6,11 +6,11 @@ | Matt Silva (thesilvanator) 05/2022 | \*-------------------------------------------*/ -#include "SinowealthGMOWController.h" #include -#include - #include +#include "LogManager.h" +#include "SinowealthGMOWController.h" +#include "StringUtils.h" SinowealthGMOWController::SinowealthGMOWController(hid_device* dev_handle, char *_path, int _type) { @@ -56,10 +56,7 @@ std::string SinowealthGMOWController::GetSerialString() return(""); } - std::wstring return_wstring = serial_string; - std::string return_string(return_wstring.begin(), return_wstring.end()); - - return(return_string); + return(StringUtils::wstring_to_string(serial_string)); } std::string SinowealthGMOWController::GetFirmwareVersion() @@ -233,4 +230,4 @@ void SinowealthGMOWController::SetMode(unsigned char mode, hid_send_feature_report(dev, less_buff, GMOW_PACKET_SIZE); -} \ No newline at end of file +}