Windows 上 D 中的 GetWindowLongPtr?
GetWindowLongPtr in D on Windows?
我无法在标准 D 的模块中找到 'GetWindowLongPtr'。所以我去了 MSDN ( https://msdn.microsoft.com/ru-ru/library/windows/desktop/ms633585(v=vs.85).aspx )。附上库:
pragma (lib, "user32.lib");
声明了一个函数:
extern (Windows)
{
export LONG_PTR GetWindowLongPtrA(in HWND hWnd, in int nIndex);
}
但是编译器 (dmd) 说:_GetWindowLongPtrA@8
此方案适用于 AppendMenu WinAPI 调用。我们我做错了什么?
GetWindowLongPtrA
仅存在于 user32.dll
的 64 位版本中。对于32位,它是GetWindowLongA
.
的宏
要获得更全面的 Windows 绑定,您应该查看 Windows 绑定项目:
我无法在标准 D 的模块中找到 'GetWindowLongPtr'。所以我去了 MSDN ( https://msdn.microsoft.com/ru-ru/library/windows/desktop/ms633585(v=vs.85).aspx )。附上库:
pragma (lib, "user32.lib");
声明了一个函数:
extern (Windows)
{
export LONG_PTR GetWindowLongPtrA(in HWND hWnd, in int nIndex);
}
但是编译器 (dmd) 说:_GetWindowLongPtrA@8
此方案适用于 AppendMenu WinAPI 调用。我们我做错了什么?
GetWindowLongPtrA
仅存在于 user32.dll
的 64 位版本中。对于32位,它是GetWindowLongA
.
要获得更全面的 Windows 绑定,您应该查看 Windows 绑定项目: