diff options
| author | Michael R Sweet <michael.r.sweet@gmail.com> | 1999-12-06 14:43:40 +0000 |
|---|---|---|
| committer | Michael R Sweet <michael.r.sweet@gmail.com> | 1999-12-06 14:43:40 +0000 |
| commit | 1e3bc4ba57812865f91eef24a47556a08a340b3b (patch) | |
| tree | f6fe9adee66e19f72d5f0d3526b0c38bed951164 | |
| parent | 6ffdd70246d4d22e11b31748fa04eccb7e43bd3c (diff) | |
Minor change - now check the version of Windows we have to
determine if we should use the built-in hand cursor instead of up-
arrow...
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.0@936 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
| -rw-r--r-- | src/fl_cursor.cxx | 19 |
1 files changed, 16 insertions, 3 deletions
diff --git a/src/fl_cursor.cxx b/src/fl_cursor.cxx index 74848bcd4..95efcc080 100644 --- a/src/fl_cursor.cxx +++ b/src/fl_cursor.cxx @@ -1,5 +1,5 @@ // -// "$Id: fl_cursor.cxx,v 1.6.2.1 1999/12/05 13:59:26 mike Exp $" +// "$Id: fl_cursor.cxx,v 1.6.2.2 1999/12/06 14:43:40 mike Exp $" // // Mouse cursor support for the Fast Light Tool Kit (FLTK). // @@ -61,7 +61,20 @@ void Fl_Window::cursor(Fl_Cursor c, Fl_Color, Fl_Color) { case FL_CURSOR_WAIT: n = IDC_WAIT; break; case FL_CURSOR_INSERT: n = IDC_IBEAM; break; case FL_CURSOR_HELP: n = IDC_HELP; break; - case FL_CURSOR_HAND: n = IDC_HAND; break; + case FL_CURSOR_HAND: { + OSVERSIONINFO osvi; + + // Get the OS version: Windows 98 and 2000 have a standard + // hand cursor. + memset(&osvi, 0, sizeof(OSVERSIONINFO)); + osvi.dwOSVersionInfoSize = sizeof(OSVERSIONINFO); + GetVersionEx(&osvi); + + if (osvi.dwMajorVersion > 4 || + (osvi.dwMajorVersion == 4 && osvi.dwMinorVersion > 0 && + osvi.dwPlatformId == VER_PLATFORM_WIN32_WINDOWS)) n = IDC_HAND; + else n = IDC_UPARROW; + } break; case FL_CURSOR_MOVE: n = IDC_SIZEALL; break; case FL_CURSOR_N: case FL_CURSOR_S: @@ -171,5 +184,5 @@ void Fl_Window::cursor(Fl_Cursor c, Fl_Color fg, Fl_Color bg) { #endif // -// End of "$Id: fl_cursor.cxx,v 1.6.2.1 1999/12/05 13:59:26 mike Exp $". +// End of "$Id: fl_cursor.cxx,v 1.6.2.2 1999/12/06 14:43:40 mike Exp $". // |
