From 314c07b152f9973d90cef3e99fa299db5bb1c2df Mon Sep 17 00:00:00 2001 From: LiFan <2308045698@qq.com> Date: 星期四, 27 六月 2024 22:50:10 +0800 Subject: [PATCH] update SO --- jrj/xframe/win32/win.hpp | 24 +++++++++++++++--------- 1 files changed, 15 insertions(+), 9 deletions(-) diff --git a/jrj/xframe/win32/win.hpp b/jrj/xframe/win32/win.hpp index e32f9d2..0b12726 100644 --- a/jrj/xframe/win32/win.hpp +++ b/jrj/xframe/win32/win.hpp @@ -29,12 +29,6 @@ #define WINAPI __stdcall -#define SendMessage SendMessageW -#define PostMessage PostMessageW -#define GetWindowLong GetWindowLongW -#define SetWindowLong SetWindowLongW -#define MessageBox MessageBoxW - extern "C" { void WINAPI SysFreeString(BSTR str);//OleAut32.dll @@ -66,8 +60,8 @@ bool WINAPI AnimateWindow(HWND hWnd,int dwTime,int dwFlags) ;//native from "user32.dll" alias "AnimateWindow"; int WINAPI GetKeyState(int nVirtKey) ;//native from "user32.dll" alias "GetKeyState"; - int WINAPI SetWindowLong(HWND hWnd, int nIndex, int dwNewLong) ;//native from "user32.dll" alias "SetWindowLongW"; - LPARAM WINAPI GetWindowLong(HWND hWnd, int nIndex) ;//native from "user32.dll" alias "GetWindowLongW"; + int WINAPI SetWindowLongW(HWND hWnd, int nIndex, int dwNewLong) ;//native from "user32.dll" alias "SetWindowLongW"; + LPARAM WINAPI GetWindowLongW(HWND hWnd, int nIndex) ;//native from "user32.dll" alias "GetWindowLongW"; int WINAPI GetClientRect(HWND hWnd, xrect & lpRect) ;//native from "user32.dll" alias "GetClientRect"; int WINAPI GetWindowRect(HWND hWnd, xrect & lpRect) ;//native from "user32.dll" alias "GetWindowRect"; int WINAPI MoveWindow(HWND hWnd, int X, int Y, int nWidth, int nHeight, bool bRepaint) ;//native from "user32.dll" alias "MoveWindow"; @@ -111,9 +105,20 @@ int WINAPI GetTempPathW(int NAME_LEN,string & OutPath) ;//native from "kernel32.dll" alias "GetTempPathW"; int WINAPI GetModuleHandleW(string lpModuleName) ;//native from "kernel32.dll" alias "GetModuleHandleW"; - int WINAPI GetModuleFileName(int hModule ,string & lpFileName ,int nSize ) ;//native from "kernel32.dll" alias "GetModuleFileName"; + int WINAPI GetModuleFileNameW(int hModule ,string lpFileName, int nSize);//native from "kernel32.dll" alias "GetModuleFileNameW"; void WINAPI GetLocalTime(SYSTEMTIME& lpSystemTime) ;//native from "kernel32.dll" alias "GetLocalTime"; + int WINAPI PathRemoveFileSpecW(string lpFileName);// native from "shlwapi.dll" alias "PathRemoveFileSpecW"; + } +#define SendMessage SendMessageW +#define PostMessage PostMessageW +#define GetWindowLong GetWindowLongW +#define SetWindowLong SetWindowLongW +#define MessageBox MessageBoxW +#define GetModuleFileName GetModuleFileNameW +#define PathRemoveFileSpec PathRemoveFileSpecW +#define SetWindowText SetWindowTextW +#define GetWindowText GetWindowTextW #if 0 namespace win32 @@ -193,5 +198,6 @@ int GetModuleHandleW(string lpModuleName) ;//native from "kernel32.dll" alias "GetModuleHandleW"; int GetModuleFileName(int hModule ,string & lpFileName ,int nSize ) ;//native from "kernel32.dll" alias "GetModuleFileName"; void GetLocalTime(SYSTEMTIME& lpSystemTime) ;//native from "kernel32.dll" alias "GetLocalTime"; + } #endif \ No newline at end of file -- Gitblit v1.9.3