mirror of
https://git.code.sf.net/p/zint/code
synced 2025-05-15 07:34:35 -04:00
Merge Windows platform patches by tgotic
This commit is contained in:
parent
f121cf65ac
commit
b65cd26527
33 changed files with 1093 additions and 129 deletions
31
backend/dllversion.c
Normal file
31
backend/dllversion.c
Normal file
|
@ -0,0 +1,31 @@
|
|||
/* Sed: http://msdn.microsoft.com/library/en-us/shellcc/platform/shell/programmersguide/versions.asp */
|
||||
#if defined (_WIN32) && (defined(_USRDLL) || defined(DLL_EXPORT) || defined(PIC))
|
||||
#include <windows.h>
|
||||
#include <shlwapi.h>
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C"
|
||||
{
|
||||
#endif
|
||||
|
||||
__declspec(dllexport) HRESULT DllGetVersion (DLLVERSIONINFO2* pdvi);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
HRESULT DllGetVersion (DLLVERSIONINFO2* pdvi)
|
||||
{
|
||||
if (!pdvi || (sizeof(*pdvi) != pdvi->info1.cbSize))
|
||||
return (E_INVALIDARG);
|
||||
|
||||
pdvi->info1.dwMajorVersion = 2;
|
||||
pdvi->info1.dwMinorVersion = 1;
|
||||
pdvi->info1.dwBuildNumber = 3;
|
||||
pdvi->info1.dwPlatformID = DLLVER_PLATFORM_WINDOWS;
|
||||
if (sizeof(DLLVERSIONINFO2) == pdvi->info1.cbSize)
|
||||
pdvi->ullVersion = MAKEDLLVERULL(2, 1, 3, 0);
|
||||
|
||||
return S_OK;
|
||||
}
|
||||
#endif /* _WIN32 */
|
Loading…
Add table
Add a link
Reference in a new issue