aboutsummaryrefslogtreecommitdiff
path: root/jim-win32.c
diff options
context:
space:
mode:
authorpatthoyts <patthoyts>2005-04-08 14:07:23 +0000
committerpatthoyts <patthoyts>2005-04-08 14:07:23 +0000
commitd8bfdd4b5111ab604ab52dc9d3b1ee09be604801 (patch)
tree0b15df66a5876cc9656929d3451f848ed8ae66e4 /jim-win32.c
parentf4a8622a0255367dfd9036ca342b02923dee1645 (diff)
downloadjimtcl-d8bfdd4b5111ab604ab52dc9d3b1ee09be604801.zip
jimtcl-d8bfdd4b5111ab604ab52dc9d3b1ee09be604801.tar.gz
jimtcl-d8bfdd4b5111ab604ab52dc9d3b1ee09be604801.tar.bz2
Do not add cursorinfo if build target cannot cope.
Diffstat (limited to 'jim-win32.c')
-rw-r--r--jim-win32.c9
1 files changed, 7 insertions, 2 deletions
diff --git a/jim-win32.c b/jim-win32.c
index dc4b8aa..6bbb09f 100644
--- a/jim-win32.c
+++ b/jim-win32.c
@@ -2,7 +2,7 @@
*
* Copyright (C) 2005 Pat Thoyts <patthoyts@users.sourceforge.net>
*
- * $Id: jim-win32.c,v 1.23 2005/04/06 13:08:01 patthoyts Exp $
+ * $Id: jim-win32.c,v 1.24 2005/04/08 14:07:23 patthoyts Exp $
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -489,6 +489,7 @@ Win32_GetPerformanceInfo(Jim_Interp *interp, int objc, Jim_Obj *const *objv)
return JIM_OK;
}
+#if WINVER >= 0x0500
static int
Win32_GetCursorInfo(Jim_Interp *interp, int objc, Jim_Obj *const objv[])
{
@@ -518,6 +519,7 @@ Win32_GetCursorInfo(Jim_Interp *interp, int objc, Jim_Obj *const objv[])
Jim_SetResult(interp, Jim_NewListObj(interp, a, n));
return JIM_OK;
}
+#endif /* WINVER >= 0x0500 */
static int
Win32_GetCursorPos(Jim_Interp *interp, int objc, Jim_Obj *const objv[])
@@ -750,7 +752,6 @@ Jim_OnLoad(Jim_Interp *interp)
CMD(GetActiveWindow);
CMD(SetActiveWindow);
CMD(SetForegroundWindow);
- CMD(GetCursorInfo);
CMD(GetCursorPos);
CMD(SetCursorPos);
CMD(GetCursor);
@@ -768,6 +769,10 @@ Jim_OnLoad(Jim_Interp *interp)
CMD(LoadLibrary);
CMD(FreeLibrary);
+#if WINVER >= 0x0500
+ CMD(GetCursorInfo);
+#endif
+
/* Check that this DLL is available before creating the command. */
hLib = LoadLibrary(_T("psapi"));
if (hLib != NULL) {