diff options
author | Ted Jump <tjump@users.sourceforge.net> | 1999-09-17 03:07:28 +0000 |
---|---|---|
committer | Ted Jump <tjump@users.sourceforge.net> | 1999-09-17 03:07:28 +0000 |
commit | 1f256fd6b39572e16cadb6460b865a128103bf18 (patch) | |
tree | e0461234d70b65b6bef85d41e0d25c4ef31db87b /src/glut | |
parent | 3849b44d666482a14aac41f4e19a596c420cfa80 (diff) |
Win32 build req't updates
Diffstat (limited to 'src/glut')
-rw-r--r-- | src/glut/glx/glut_cursor.c | 2 | ||||
-rw-r--r-- | src/glut/glx/win32_menu.c | 23 | ||||
-rw-r--r-- | src/glut/glx/win32_util.c | 1 |
3 files changed, 13 insertions, 13 deletions
diff --git a/src/glut/glx/glut_cursor.c b/src/glut/glx/glut_cursor.c index 74ecb9cd66..28e95568d6 100644 --- a/src/glut/glx/glut_cursor.c +++ b/src/glut/glx/glut_cursor.c @@ -164,7 +164,7 @@ __glutSetCursor(GLUTwindow *window) break; case GLUT_CURSOR_FULL_CROSSHAIR: #if defined(_WIN32) - xcursor = IDC_CROSS; + xcursor = (HICON) IDC_CROSS; #else if (fullCrosshairCusor == None) { fullCrosshairCusor = getFullCrosshairCursor(); diff --git a/src/glut/glx/win32_menu.c b/src/glut/glx/win32_menu.c index 9b330644af..20485eea65 100644 --- a/src/glut/glx/win32_menu.c +++ b/src/glut/glx/win32_menu.c @@ -96,9 +96,8 @@ __glutFinishMenu(Window win, int x, int y) static void mapMenu(GLUTmenu * menu, int x, int y) { - TrackPopupMenu(menu->win, TPM_LEFTALIGN | - __glutMenuButton == TPM_RIGHTBUTTON ? - TPM_RIGHTBUTTON : TPM_LEFTBUTTON, + TrackPopupMenu((HMENU) menu->win, TPM_LEFTALIGN | + (__glutMenuButton == TPM_RIGHTBUTTON) ? TPM_RIGHTBUTTON : TPM_LEFTBUTTON, x, y, 0, __glutCurrentWindow->win, NULL); } @@ -254,7 +253,7 @@ glutCreateMenu(GLUTselectCB selectFunc) menu->cascade = NULL; menu->highlighted = NULL; menu->anchor = NULL; - menu->win = CreatePopupMenu(); + menu->win = (HWND) CreatePopupMenu(); menuList[menuid] = menu; __glutSetMenu(menu); return menuid + 1; @@ -277,7 +276,7 @@ glutDestroyMenu(int menunum) menuModificationError(); } assert(menu->id == menunum - 1); - DestroyMenu(menu->win); + DestroyMenu( (HMENU) menu->win); menuList[menunum - 1] = NULL; /* free all menu entries */ item = menu->list; @@ -337,9 +336,9 @@ setMenuItem(GLUTmenuItem * item, const char *label, item->value = value; item->unique = uniqueMenuHandler++; if (isTrigger) { - AppendMenu(menu->win, MF_POPUP, (UINT)item->win, label); + AppendMenu((HMENU) menu->win, MF_POPUP, (UINT)item->win, label); } else { - AppendMenu(menu->win, MF_STRING, item->unique, label); + AppendMenu((HMENU) menu->win, MF_STRING, item->unique, label); } } @@ -405,7 +404,7 @@ glutChangeToMenuEntry(int num, const char *label, int value) need to account for submenus. */ item->menu->submenus--; /* Nuke the Win32 menu. */ - DestroyMenu(item->win); + DestroyMenu((HMENU) item->win); } free(item->label); @@ -416,7 +415,7 @@ glutChangeToMenuEntry(int num, const char *label, int value) item->len = (int) strlen(label); item->value = value; item->unique = uniqueMenuHandler++; - ModifyMenu(__glutCurrentMenu->win, (UINT) i - 1, + ModifyMenu((HMENU) __glutCurrentMenu->win, (UINT) i - 1, MF_BYPOSITION | MFT_STRING, item->unique, label); return; @@ -445,7 +444,7 @@ glutChangeToSubMenu(int num, const char *label, int menu) /* If changing a menu entry to as submenu trigger, we need to account for submenus. */ item->menu->submenus++; - item->win = CreatePopupMenu(); + item->win = (HWND) CreatePopupMenu(); } free(item->label); @@ -459,7 +458,7 @@ glutChangeToSubMenu(int num, const char *label, int menu) popupmenu = __glutGetMenuByNum(menu); if (popupmenu) item->win = popupmenu->win; - ModifyMenu(__glutCurrentMenu->win, (UINT) i - 1, + ModifyMenu((HMENU) __glutCurrentMenu->win, (UINT) i - 1, MF_BYPOSITION | MF_POPUP, (UINT) item->win, label); return; } @@ -489,7 +488,7 @@ glutRemoveMenuItem(int num) /* Patch up menu's item list. */ *prev = item->next; - RemoveMenu(__glutCurrentMenu->win, (UINT) i - 1, MF_BYPOSITION); + RemoveMenu((HMENU) __glutCurrentMenu->win, (UINT) i - 1, MF_BYPOSITION); free(item->label); free(item); diff --git a/src/glut/glx/win32_util.c b/src/glut/glx/win32_util.c index d00a24210b..8dc714c035 100644 --- a/src/glut/glx/win32_util.c +++ b/src/glut/glx/win32_util.c @@ -70,6 +70,7 @@ __glutFont(void *font) } __glutFatalError("out of memory."); /* NOTREACHED */ + return NULL; /* MSVC compiler complains if there is no return at all */ } int |