comparison include/animone/util/win32.h @ 3:aa55bcfb5b79

win32: make builds work again
author Paper <paper@paper.us.eu.org>
date Thu, 11 Apr 2024 23:39:18 -0400
parents a76fa32bdc92
children 27b988a1048c
comparison
equal deleted inserted replaced
2:97ea6a3e1954 3:aa55bcfb5b79
1 #ifndef ANIMONE_ANIMONE_UTIL_WIN32_H_ 1 #ifndef ANIMONE_ANIMONE_UTIL_WIN32_H_
2 #define ANIMONE_ANIMONE_UTIL_WIN32_H_ 2 #define ANIMONE_ANIMONE_UTIL_WIN32_H_
3 3
4 #include <windef.h>
4 #include <subauth.h> 5 #include <subauth.h>
5 #include <windows.h> 6 #include <handleapi.h>
6 7
7 #include <memory> 8 #include <memory>
8 #include <string> 9 #include <string>
9 10
10 namespace animone::internal::win32 { 11 namespace animone::internal::win32 {
20 21
21 std::string ToUtf8String(const std::wstring& string); 22 std::string ToUtf8String(const std::wstring& string);
22 std::string ToUtf8String(const UNICODE_STRING& string); 23 std::string ToUtf8String(const UNICODE_STRING& string);
23 std::wstring ToWstring(const std::string& string); 24 std::wstring ToWstring(const std::string& string);
24 25
26 std::wstring GetProcessPath(DWORD process_id);
25 std::wstring GetFileNameFromPath(const std::wstring& path); 27 std::wstring GetFileNameFromPath(const std::wstring& path);
26 std::wstring GetFileNameWithoutExtension(const std::wstring& filename); 28 std::wstring GetFileNameWithoutExtension(const std::wstring& filename);
27 29
28 bool IsSystemDirectory(const std::string& path); 30 bool IsSystemDirectory(const std::string& path);
29 bool IsSystemDirectory(std::wstring path); 31 bool IsSystemDirectory(std::wstring path);