At 20:19 11-7-2009 -0600, Eric Mullins wrote:
Aside from warnings, one reason for my patch was to allow this to compile in MSVC 6.x and 4.1.

OK, I overlooked something. I first made the HTML patch using the htmHelp.h and htmlHelp.lib provided by the Html Help Workshop. But when I found out that you only have to call a Hh.exe I thought it would be better to make the compile inot dependent on this, and provide my own code to do it. I did want to keep the originl data type for HtmlHelp(), though, becase in future versions of Windows HtmlHelp might be so standard that it gets defined in windows.h like WinHelp() apparently is now, and then we could simply switch back to it by deleting
my code for HtmlHelp.

The htmlhelp.h did contain the definition with DWORD_PTR, and since it did not raise any complaints from the compiler I assumed it was a standard Windows type, but what I overooked
was that it was redefined it earlier in the file:

// Defines for Win64
#ifndef _WIN64
#define DWORD_PTR DWORD
#endif


HWND
WINAPI
HtmlHelpA(
    HWND hwndCaller,
    LPCSTR pszFile,
    UINT uCommand,
    DWORD_PTR dwData
    );

HWND
WINAPI
HtmlHelpW(
    HWND hwndCaller,
    LPCWSTR pszFile,
    UINT uCommand,
    DWORD_PTR dwData
    );
#ifdef UNICODE
#define HtmlHelp  HtmlHelpW
#else
#define HtmlHelp  HtmlHelpA
#endif // !UNICODE

Reply via email to