Tk Source Code

View Ticket
Login
Ticket UUID: 1210712
Title: mingw needs _WIN32_WINNT = 0x0403 for SendInput API
Type: Bug Version: obsolete: 8.5a3
Submitter: tngd Created on: 2005-05-29 10:10:06
Subsystem: 85. Win Build Assigned To: mdejong
Priority: 5 Medium Severity:
Status: Closed Last Modified: 2005-07-23 10:08:19
Resolution: Fixed Closed By: mdejong
    Closed on: 2005-07-23 03:08:19
Description:
When building with Mingw32, SendInput API requires
_WIN32_WINNT to be at least 0x0403 to be declared (in
file winable.h).
User Comments: mdejong added on 2005-07-23 10:08:19:
Logged In: YES 
user_id=90858

Fixed in CVS as of 7/22/05. Note that an upgrade to
msys_mingw7.zip is needed to build under Mingw.

magro added on 2005-07-13 13:24:43:
Logged In: YES 
user_id=83653

Changed _WIN32_WINNT in tkWinX.c accordingly, but get still
the same error. W2K/SP4

mic42 added on 2005-07-13 07:25:36:
Logged In: YES 
user_id=302287

This code at the top of tkWinX.c is simply wrong:
/*
 * Make sure the SendInput API is available:
 */
#if (_WIN32_WINNT <= 0x0400)
#undef _WIN32_WINNT
#define _WIN32_WINNT 0x0401
#endif

#include "tkWinInt.h"

it has to be:
/*
 * Make sure the SendInput API is available:
 */
#if (_WIN32_WINNT <= 0x0400)
#undef _WIN32_WINNT
#define _WIN32_WINNT 0x0403
#endif

#include "tkWinInt.h"

for SendInput to be available (NT4 SP 3) not NT4 Service Pack 1.

Michael