comparison win/dw.c @ 45:90aa71b3298a

Fixed makefile for Windows, and updated to latest source.
author bsmith@81767d24-ef19-dc11-ae90-00e081727c95
date Tue, 30 Oct 2001 10:15:44 +0000
parents 88c9c7410c22
children 30d091bc7899
comparison
equal deleted inserted replaced
44:24afe3035088 45:90aa71b3298a
218 argv = _convertargs(&argc, lpCmdLine); 218 argv = _convertargs(&argc, lpCmdLine);
219 219
220 return main(argc, argv); 220 return main(argc, argv);
221 } 221 }
222 #endif 222 #endif
223
224 /* This should return true for WinNT/2K/XP and false on Win9x */
225 int IsWinNT(void)
226 {
227 static int isnt = -1;
228
229 if(isnt == -1)
230 {
231 if (GetVersion() < 0x80000000)
232 isnt = 1;
233 else
234 isnt = 0;
235 }
236 return isnt;
237 }
223 238
224 /* This function adds a signal handler callback into the linked list. 239 /* This function adds a signal handler callback into the linked list.
225 */ 240 */
226 void _new_signal(ULONG message, HWND window, void *signalfunction, void *data) 241 void _new_signal(ULONG message, HWND window, void *signalfunction, void *data)
227 { 242 {
1579 1594
1580 /* Tell the spinner control that a keypress has 1595 /* Tell the spinner control that a keypress has
1581 * occured and to update it's internal value. 1596 * occured and to update it's internal value.
1582 */ 1597 */
1583 if(cinfo->buddy && !cinfo->combo) 1598 if(cinfo->buddy && !cinfo->combo)
1584 SendMessage(cinfo->buddy, WM_USER+10, 0, 0); 1599 {
1600 if(IsWinNT())
1601 PostMessage(cinfo->buddy, WM_USER+10, 0, 0);
1602 else
1603 SendMessage(cinfo->buddy, WM_USER+10, 0, 0);
1604 }
1585 break; 1605 break;
1586 case WM_USER+10: 1606 case WM_USER+10:
1587 { 1607 {
1588 if(cinfo->buddy) 1608 if(cinfo->buddy)
1589 { 1609 {