Screenshot instructions:
Windows
Mac
Red Hat Linux
Ubuntu
Click URL instructions:
Right-click on ad, choose "Copy Link", then paste here →
(This may not be possible with some types of ads)
You can subscribe to this list here.
2003 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
(6) |
Aug
(31) |
Sep
(34) |
Oct
(74) |
Nov
(88) |
Dec
(66) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2004 |
Jan
(11) |
Feb
(21) |
Mar
(26) |
Apr
(1) |
May
(9) |
Jun
(2) |
Jul
|
Aug
(8) |
Sep
(8) |
Oct
(4) |
Nov
|
Dec
(8) |
2005 |
Jan
(34) |
Feb
(5) |
Mar
(1) |
Apr
(20) |
May
(34) |
Jun
(24) |
Jul
(28) |
Aug
(4) |
Sep
(3) |
Oct
(5) |
Nov
|
Dec
|
2006 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
(3) |
Sep
(15) |
Oct
|
Nov
(1) |
Dec
|
2007 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
(16) |
Oct
(5) |
Nov
(3) |
Dec
(4) |
2008 |
Jan
(1) |
Feb
|
Mar
|
Apr
(1) |
May
|
Jun
|
Jul
(2) |
Aug
|
Sep
|
Oct
|
Nov
(19) |
Dec
|
2009 |
Jan
|
Feb
(26) |
Mar
(20) |
Apr
(4) |
May
(11) |
Jun
(2) |
Jul
(4) |
Aug
(1) |
Sep
|
Oct
|
Nov
(21) |
Dec
(13) |
2010 |
Jan
(8) |
Feb
(1) |
Mar
|
Apr
|
May
(1) |
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
(2) |
Dec
|
2011 |
Jan
(12) |
Feb
|
Mar
(24) |
Apr
|
May
(6) |
Jun
(4) |
Jul
|
Aug
|
Sep
(15) |
Oct
|
Nov
(5) |
Dec
(16) |
2012 |
Jan
(64) |
Feb
(44) |
Mar
(137) |
Apr
(48) |
May
(53) |
Jun
(21) |
Jul
(34) |
Aug
(8) |
Sep
(2) |
Oct
|
Nov
(97) |
Dec
(3) |
2013 |
Jan
(10) |
Feb
(32) |
Mar
(34) |
Apr
(48) |
May
(7) |
Jun
|
Jul
|
Aug
(1) |
Sep
|
Oct
|
Nov
(1) |
Dec
|
2014 |
Jan
(48) |
Feb
|
Mar
(2) |
Apr
(1) |
May
(5) |
Jun
(9) |
Jul
|
Aug
(10) |
Sep
(1) |
Oct
(19) |
Nov
(4) |
Dec
(3) |
2015 |
Jan
(6) |
Feb
(7) |
Mar
(7) |
Apr
|
May
|
Jun
(10) |
Jul
(3) |
Aug
|
Sep
|
Oct
(3) |
Nov
|
Dec
(6) |
2016 |
Jan
(11) |
Feb
(1) |
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2017 |
Jan
|
Feb
|
Mar
|
Apr
(7) |
May
(4) |
Jun
(23) |
Jul
(8) |
Aug
|
Sep
|
Oct
(2) |
Nov
|
Dec
|
2018 |
Jan
|
Feb
|
Mar
(4) |
Apr
(1) |
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
S | M | T | W | T | F | S |
---|---|---|---|---|---|---|
|
1
(4) |
2
|
3
(1) |
4
(13) |
5
(17) |
6
(7) |
7
(3) |
8
|
9
|
10
|
11
|
12
|
13
|
14
|
15
|
16
|
17
|
18
(1) |
19
|
20
(2) |
21
|
22
|
23
|
24
|
25
|
26
|
27
|
28
|
29
|
30
|
|
|
|
|
From: <dcnieho@us...> - 2013-04-06 14:09:07
|
Revision: 1612 http://freeglut.svn.sourceforge.net/freeglut/?rev=1612&view=rev Author: dcnieho Date: 2013-04-06 14:08:59 +0000 (Sat, 06 Apr 2013) Log Message: ----------- Menu's work again in gamemode too now. We have to do a normal ShowWindow in gamemode, or the menu won't pop up over the gamemode window. Also now using fgState.ActiveMenus instead of enumerating to see if there is an active menu Modified Paths: -------------- trunk/freeglut/freeglut/src/fg_menu.c trunk/freeglut/freeglut/src/mswin/fg_main_mswin.c trunk/freeglut/freeglut/src/mswin/fg_menu_mswin.c Modified: trunk/freeglut/freeglut/src/fg_menu.c =================================================================== --- trunk/freeglut/freeglut/src/fg_menu.c 2013-04-06 10:20:42 UTC (rev 1611) +++ trunk/freeglut/freeglut/src/fg_menu.c 2013-04-06 14:08:59 UTC (rev 1612) @@ -632,7 +632,7 @@ is_handled = GL_TRUE; } - else if ( fgStructure.Menus.First ) /* Don't have to check whether this was a downpress or an uppress, there is no way to get an uppress in another window before a downpress... */ + else if ( fgState.ActiveMenus ) /* Don't have to check whether this was a downpress or an uppress, there is no way to get an uppress in another window before a downpress... */ { /* if another window than the one clicked in has an open menu, close it */ SFG_Menu *menu = fgGetActiveMenu(); @@ -784,7 +784,7 @@ { /* The menu object creation code resides in freeglut_structure.c */ FREEGLUT_EXIT_IF_NOT_INITIALISED ( "glutCreateMenu" ); - if (fgGetActiveMenu()) + if (fgState.ActiveMenus) fgError("Menu manipulation not allowed while menus in use."); return fgCreateMenu( callback )->ID; @@ -801,7 +801,7 @@ menu = fgMenuByID( menuID ); freeglut_return_if_fail( menu ); - if (fgGetActiveMenu()) + if (fgState.ActiveMenus) fgError("Menu manipulation not allowed while menus in use."); /* The menu object destruction code resides in freeglut_structure.c */ @@ -846,7 +846,7 @@ menuEntry = (SFG_MenuEntry *)calloc( sizeof(SFG_MenuEntry), 1 ); freeglut_return_if_fail( fgStructure.CurrentMenu ); - if (fgGetActiveMenu()) + if (fgState.ActiveMenus) fgError("Menu manipulation not allowed while menus in use."); menuEntry->Text = strdup( label ); @@ -871,7 +871,7 @@ subMenu = fgMenuByID( subMenuID ); freeglut_return_if_fail( fgStructure.CurrentMenu ); - if (fgGetActiveMenu()) + if (fgState.ActiveMenus) fgError("Menu manipulation not allowed while menus in use."); freeglut_return_if_fail( subMenu ); @@ -895,7 +895,7 @@ menu = fgMenuByID( menuID ); freeglut_return_if_fail( menu ); - if (fgGetActiveMenu()) + if (fgState.ActiveMenus) fgError("Menu manipulation not allowed while menus in use."); font = fghFontByID( fontID ); @@ -919,7 +919,7 @@ FREEGLUT_EXIT_IF_NOT_INITIALISED ( "glutChangeToMenuEntry" ); freeglut_return_if_fail( fgStructure.CurrentMenu ); - if (fgGetActiveMenu()) + if (fgState.ActiveMenus) fgError("Menu manipulation not allowed while menus in use."); /* Get n-th menu entry in the current menu, starting from one: */ @@ -949,7 +949,7 @@ FREEGLUT_EXIT_IF_NOT_INITIALISED ( "glutChangeToSubMenu" ); freeglut_return_if_fail( fgStructure.CurrentMenu ); - if (fgGetActiveMenu()) + if (fgState.ActiveMenus) fgError("Menu manipulation not allowed while menus in use."); /* Get handle to sub menu */ @@ -982,7 +982,7 @@ FREEGLUT_EXIT_IF_NOT_INITIALISED ( "glutRemoveMenuItem" ); freeglut_return_if_fail( fgStructure.CurrentMenu ); - if (fgGetActiveMenu()) + if (fgState.ActiveMenus) fgError("Menu manipulation not allowed while menus in use."); /* Get n-th menu entry in the current menu, starting from one: */ @@ -1008,7 +1008,7 @@ freeglut_return_if_fail( fgStructure.CurrentWindow ); freeglut_return_if_fail( fgStructure.CurrentMenu ); - if (fgGetActiveMenu()) + if (fgState.ActiveMenus) fgError("Menu manipulation not allowed while menus in use."); freeglut_return_if_fail( button >= 0 ); @@ -1027,7 +1027,7 @@ freeglut_return_if_fail( fgStructure.CurrentWindow ); freeglut_return_if_fail( fgStructure.CurrentMenu ); - if (fgGetActiveMenu()) + if (fgState.ActiveMenus) fgError("Menu manipulation not allowed while menus in use."); freeglut_return_if_fail( button >= 0 ); Modified: trunk/freeglut/freeglut/src/mswin/fg_main_mswin.c =================================================================== --- trunk/freeglut/freeglut/src/mswin/fg_main_mswin.c 2013-04-06 10:20:42 UTC (rev 1611) +++ trunk/freeglut/freeglut/src/mswin/fg_main_mswin.c 2013-04-06 14:08:59 UTC (rev 1612) @@ -39,7 +39,7 @@ extern GLboolean fgSetupPixelFormat( SFG_Window* window, GLboolean checkOnly, unsigned char layer_type ); -extern void fgPlatformCheckMenuDeactivate(); +extern void fgPlatformCheckMenuDeactivate(HWND newFocusWnd); #ifdef WM_TOUCH typedef BOOL (WINAPI *pGetTouchInputInfo)(HTOUCHINPUT,UINT,PTOUCHINPUT,int); @@ -969,14 +969,14 @@ lRet = DefWindowProc( hWnd, uMsg, wParam, lParam ); /* Check if there are any open menus that need to be closed */ - fgPlatformCheckMenuDeactivate(); + fgPlatformCheckMenuDeactivate((HWND)wParam); break; case WM_MOUSEACTIVATE: /* Clicks should not activate the menu. * Especially important when clicking on a menu's submenu item which has no effect. */ - printf("WM_MOUSEACTIVATE\n"); + /*printf("WM_MOUSEACTIVATE\n");*/ if (window->IsMenu) lRet = MA_NOACTIVATEANDEAT; else @@ -988,7 +988,7 @@ case WM_NCRBUTTONDOWN: { SFG_Menu *menu; - if (fgStructure.Menus.First && (menu = fgGetActiveMenu())) + if (fgState.ActiveMenus && (menu = fgGetActiveMenu())) /* user clicked non-client area of window while a menu is open. Close menu */ fgDeactivateMenu(menu->ParentWindow); @@ -1767,8 +1767,8 @@ win = win->Parent; break; case DesireNormalState: - if (win->IsMenu) - cmdShow = SW_SHOWNA; /* Just show, don't activate if its a menu */ + if (win->IsMenu && (!fgStructure.GameModeWindow || win->ActiveMenu->ParentWindow != fgStructure.GameModeWindow)) + cmdShow = SW_SHOWNA; /* Just show, don't activate window if its a menu. Only exception is when the parent is a gamemode window as the menu would pop under it when we do this... */ else cmdShow = SW_SHOW; break; Modified: trunk/freeglut/freeglut/src/mswin/fg_menu_mswin.c =================================================================== --- trunk/freeglut/freeglut/src/mswin/fg_menu_mswin.c 2013-04-06 10:20:42 UTC (rev 1611) +++ trunk/freeglut/freeglut/src/mswin/fg_menu_mswin.c 2013-04-06 14:08:59 UTC (rev 1612) @@ -37,18 +37,25 @@ *y = glutGet ( GLUT_SCREEN_HEIGHT ); } -void fgPlatformCheckMenuDeactivate() +void fgPlatformCheckMenuDeactivate(HWND newFocusWnd) { /* User/system switched application focus. * If we have an open menu, close it. */ SFG_Menu* menu = NULL; - if ( fgStructure.Menus.First ) + if ( fgState.ActiveMenus ) menu = fgGetActiveMenu(); if ( menu ) - fgDeactivateMenu(menu->ParentWindow); + { + if (newFocusWnd != menu->Window->Window.Handle) + /* When in GameMode, the menu's parent window will lose focus when the menu is opened. + * This is sadly necessary as we need to do an activating ShowWindow() for the menu + * to pop up over the gamemode window + */ + fgDeactivateMenu(menu->ParentWindow); + } }; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <dcnieho@us...> - 2013-04-06 10:20:53
|
Revision: 1611 http://freeglut.svn.sourceforge.net/freeglut/?rev=1611&view=rev Author: dcnieho Date: 2013-04-06 10:20:42 +0000 (Sat, 06 Apr 2013) Log Message: ----------- cleanup a debug statement show flag should be SW_SHOWNA, not SW_SHOWNOACTIVATE according to docs Modified Paths: -------------- trunk/freeglut/freeglut/src/mswin/fg_main_mswin.c trunk/freeglut/freeglut/src/mswin/fg_menu_mswin.c Modified: trunk/freeglut/freeglut/src/mswin/fg_main_mswin.c =================================================================== --- trunk/freeglut/freeglut/src/mswin/fg_main_mswin.c 2013-04-06 10:17:04 UTC (rev 1610) +++ trunk/freeglut/freeglut/src/mswin/fg_main_mswin.c 2013-04-06 10:20:42 UTC (rev 1611) @@ -1768,7 +1768,7 @@ break; case DesireNormalState: if (win->IsMenu) - cmdShow = SW_SHOWNOACTIVATE; /* Just show, don't activate if its a menu */ + cmdShow = SW_SHOWNA; /* Just show, don't activate if its a menu */ else cmdShow = SW_SHOW; break; Modified: trunk/freeglut/freeglut/src/mswin/fg_menu_mswin.c =================================================================== --- trunk/freeglut/freeglut/src/mswin/fg_menu_mswin.c 2013-04-06 10:17:04 UTC (rev 1610) +++ trunk/freeglut/freeglut/src/mswin/fg_menu_mswin.c 2013-04-06 10:20:42 UTC (rev 1611) @@ -48,10 +48,7 @@ menu = fgGetActiveMenu(); if ( menu ) - { - printf("focus menu close\n"); fgDeactivateMenu(menu->ParentWindow); - } }; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <dcnieho@us...> - 2013-04-06 10:17:13
|
Revision: 1610 http://freeglut.svn.sourceforge.net/freeglut/?rev=1610&view=rev Author: dcnieho Date: 2013-04-06 10:17:04 +0000 (Sat, 06 Apr 2013) Log Message: ----------- clicking in another window also no longer closed the menu unless focus was changed. Fixed in click checker in general menu code, so it'll improve menus on X11 as well. Our Windows part now only needed for when losing focus because switching to a non-FreeGLUT window Modified Paths: -------------- trunk/freeglut/freeglut/src/fg_menu.c trunk/freeglut/freeglut/src/mswin/fg_menu_mswin.c Modified: trunk/freeglut/freeglut/src/fg_menu.c =================================================================== --- trunk/freeglut/freeglut/src/fg_menu.c 2013-04-06 10:16:27 UTC (rev 1609) +++ trunk/freeglut/freeglut/src/fg_menu.c 2013-04-06 10:17:04 UTC (rev 1610) @@ -568,7 +568,8 @@ * location. * - Down-click any button outside the menu, menu active: * deactivate the menu, and potentially activate a new menu - * at the new mouse location + * at the new mouse location. This includes clicks in + * different windows of course * - Down-click any button inside the menu, menu active: * select the menu entry and deactivate the menu * - Up-click the menu button, menu not active: nothing happens @@ -631,7 +632,16 @@ is_handled = GL_TRUE; } + else if ( fgStructure.Menus.First ) /* Don't have to check whether this was a downpress or an uppress, there is no way to get an uppress in another window before a downpress... */ + { + /* if another window than the one clicked in has an open menu, close it */ + SFG_Menu *menu = fgGetActiveMenu(); + if ( menu ) /* any open menu? */ + fgDeactivateMenu( menu->ParentWindow ); + /* Leave is_handled to false, we didn't do anything relevant from the perspective of the window that was clicked */ + } + /* No active menu, let's check whether we need to activate one. */ if( !is_clicked && ( 0 <= button ) && Modified: trunk/freeglut/freeglut/src/mswin/fg_menu_mswin.c =================================================================== --- trunk/freeglut/freeglut/src/mswin/fg_menu_mswin.c 2013-04-06 10:16:27 UTC (rev 1609) +++ trunk/freeglut/freeglut/src/mswin/fg_menu_mswin.c 2013-04-06 10:17:04 UTC (rev 1610) @@ -29,8 +29,6 @@ #include <GL/freeglut.h> #include "../fg_internal.h" -extern void fghGetClientArea( RECT *clientRect, const SFG_Window *window, BOOL posIsOutside ); -extern SFG_Window* fghWindowUnderCursor(SFG_Window *window); GLvoid fgPlatformGetGameModeVMaxExtent( SFG_Window* window, int* x, int* y ) @@ -41,10 +39,8 @@ void fgPlatformCheckMenuDeactivate() { - /* If we have an open menu, see if the open menu should be closed - * when focus was lost because user either switched - * application or FreeGLUT window (if one is running multiple - * windows). If so, close menu the active menu. + /* User/system switched application focus. + * If we have an open menu, close it. */ SFG_Menu* menu = NULL; @@ -53,36 +49,8 @@ if ( menu ) { - SFG_Window* wnd = NULL; - HWND hwnd = GetFocus(); /* Get window with current focus - NULL for non freeglut windows */ - if (hwnd) - /* See which of our windows it is */ - wnd = fgWindowByHandle(hwnd); - - if (!hwnd || !wnd) - /* User switched to another application*/ - fgDeactivateMenu(menu->ParentWindow); - else if (!wnd->IsMenu) /* Make sure we don't kill the menu when trying to enter a submenu */ - { - /* we need to know if user clicked a child window, any displayable area clicked that is not the menu's parent window should close the menu */ - wnd = fghWindowUnderCursor(wnd); - if (wnd!=menu->ParentWindow) - /* User switched to another FreeGLUT window */ - fgDeactivateMenu(menu->ParentWindow); - else - { - /* Check if focus lost because non-client area of - * window was pressed (pressing on client area is - * handled in fgCheckActiveMenu) - */ - POINT mouse_pos; - RECT clientArea; - fghGetClientArea(&clientArea,menu->ParentWindow, FALSE); - GetCursorPos(&mouse_pos); - if ( !PtInRect( &clientArea, mouse_pos ) ) - fgDeactivateMenu(menu->ParentWindow); - } - } + printf("focus menu close\n"); + fgDeactivateMenu(menu->ParentWindow); } }; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <dcnieho@us...> - 2013-04-06 10:16:38
|
Revision: 1609 http://freeglut.svn.sourceforge.net/freeglut/?rev=1609&view=rev Author: dcnieho Date: 2013-04-06 10:16:27 +0000 (Sat, 06 Apr 2013) Log Message: ----------- now that menu's no longer take focus from their parent, clicking the non-client area of the parent no longer closed the menu. fixed. Modified Paths: -------------- trunk/freeglut/freeglut/src/mswin/fg_main_mswin.c Modified: trunk/freeglut/freeglut/src/mswin/fg_main_mswin.c =================================================================== --- trunk/freeglut/freeglut/src/mswin/fg_main_mswin.c 2013-04-06 10:15:53 UTC (rev 1608) +++ trunk/freeglut/freeglut/src/mswin/fg_main_mswin.c 2013-04-06 10:16:27 UTC (rev 1609) @@ -983,6 +983,20 @@ lRet = DefWindowProc( hWnd, uMsg, wParam, lParam ); break; + case WM_NCLBUTTONDOWN: + case WM_NCMBUTTONDOWN: + case WM_NCRBUTTONDOWN: + { + SFG_Menu *menu; + if (fgStructure.Menus.First && (menu = fgGetActiveMenu())) + /* user clicked non-client area of window while a menu is open. Close menu */ + fgDeactivateMenu(menu->ParentWindow); + + /* and always pass to DefWindowProc */ + lRet = DefWindowProc( hWnd, uMsg, wParam, lParam ); + } + break; + #if 0 case WM_ACTIVATE: /* printf("WM_ACTIVATE: %x (ID: %i) %d %d\n",lParam, window->ID, HIWORD(wParam), LOWORD(wParam)); */ This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <dcnieho@us...> - 2013-04-06 10:16:05
|
Revision: 1608 http://freeglut.svn.sourceforge.net/freeglut/?rev=1608&view=rev Author: dcnieho Date: 2013-04-06 10:15:53 +0000 (Sat, 06 Apr 2013) Log Message: ----------- added a function to translate WM_ messages to text, for debugging Modified Paths: -------------- trunk/freeglut/freeglut/src/mswin/fg_main_mswin.c Modified: trunk/freeglut/freeglut/src/mswin/fg_main_mswin.c =================================================================== --- trunk/freeglut/freeglut/src/mswin/fg_main_mswin.c 2013-04-06 10:15:19 UTC (rev 1607) +++ trunk/freeglut/freeglut/src/mswin/fg_main_mswin.c 2013-04-06 10:15:53 UTC (rev 1608) @@ -62,7 +62,390 @@ struct GXKeyList gxKeyList; #endif /* _WIN32_WCE */ +#ifdef _DEBUG +/* + * WM_ message to string, for debugging + * This is taken from the 8.0 SDK, so Windows 8 API and everything earlier is included + */ +struct WM_MESSAGE_MAP +{ + UINT nMsg; + LPCSTR lpszMsg; +}; +#define DEFINE_MESSAGE(wm){ wm, #wm } +static struct WM_MESSAGE_MAP allMessages[] = +{ + DEFINE_MESSAGE(WM_NULL), + DEFINE_MESSAGE(WM_CREATE), + DEFINE_MESSAGE(WM_DESTROY), + DEFINE_MESSAGE(WM_MOVE), + DEFINE_MESSAGE(WM_SIZE), + DEFINE_MESSAGE(WM_ACTIVATE), + DEFINE_MESSAGE(WM_SETFOCUS), + DEFINE_MESSAGE(WM_KILLFOCUS), + DEFINE_MESSAGE(WM_ENABLE), + DEFINE_MESSAGE(WM_SETREDRAW), + DEFINE_MESSAGE(WM_SETTEXT), + DEFINE_MESSAGE(WM_GETTEXT), + DEFINE_MESSAGE(WM_GETTEXTLENGTH), + DEFINE_MESSAGE(WM_PAINT), + DEFINE_MESSAGE(WM_CLOSE), +# ifndef _WIN32_WCE + DEFINE_MESSAGE(WM_QUERYENDSESSION), + DEFINE_MESSAGE(WM_QUERYOPEN), + DEFINE_MESSAGE(WM_ENDSESSION), +# endif + DEFINE_MESSAGE(WM_QUIT), + DEFINE_MESSAGE(WM_ERASEBKGND), + DEFINE_MESSAGE(WM_SYSCOLORCHANGE), + DEFINE_MESSAGE(WM_SHOWWINDOW), + DEFINE_MESSAGE(WM_WININICHANGE), + + DEFINE_MESSAGE(WM_DEVMODECHANGE), + DEFINE_MESSAGE(WM_ACTIVATEAPP), + DEFINE_MESSAGE(WM_FONTCHANGE), + DEFINE_MESSAGE(WM_TIMECHANGE), + DEFINE_MESSAGE(WM_CANCELMODE), + DEFINE_MESSAGE(WM_SETCURSOR), + DEFINE_MESSAGE(WM_MOUSEACTIVATE), + DEFINE_MESSAGE(WM_CHILDACTIVATE), + DEFINE_MESSAGE(WM_QUEUESYNC), + + DEFINE_MESSAGE(WM_GETMINMAXINFO), + + DEFINE_MESSAGE(WM_PAINTICON), + DEFINE_MESSAGE(WM_ICONERASEBKGND), + DEFINE_MESSAGE(WM_NEXTDLGCTL), + DEFINE_MESSAGE(WM_SPOOLERSTATUS), + DEFINE_MESSAGE(WM_DRAWITEM), + DEFINE_MESSAGE(WM_MEASUREITEM), + DEFINE_MESSAGE(WM_DELETEITEM), + DEFINE_MESSAGE(WM_VKEYTOITEM), + DEFINE_MESSAGE(WM_CHARTOITEM), + DEFINE_MESSAGE(WM_SETFONT), + DEFINE_MESSAGE(WM_GETFONT), + DEFINE_MESSAGE(WM_SETHOTKEY), + DEFINE_MESSAGE(WM_GETHOTKEY), + DEFINE_MESSAGE(WM_QUERYDRAGICON), + DEFINE_MESSAGE(WM_COMPAREITEM), +# if(WINVER >= 0x0500) +# ifndef _WIN32_WCE + DEFINE_MESSAGE(WM_GETOBJECT), + # endif +# endif /* WINVER >= 0x0500 */ + DEFINE_MESSAGE(WM_COMPACTING), + DEFINE_MESSAGE(WM_COMMNOTIFY), + DEFINE_MESSAGE(WM_WINDOWPOSCHANGING), + DEFINE_MESSAGE(WM_WINDOWPOSCHANGED), + + DEFINE_MESSAGE(WM_POWER), + + DEFINE_MESSAGE(WM_COPYDATA), + DEFINE_MESSAGE(WM_CANCELJOURNAL), + +# if(WINVER >= 0x0400) + DEFINE_MESSAGE(WM_NOTIFY), + DEFINE_MESSAGE(WM_INPUTLANGCHANGEREQUEST), + DEFINE_MESSAGE(WM_INPUTLANGCHANGE), + DEFINE_MESSAGE(WM_TCARD), + DEFINE_MESSAGE(WM_HELP), + DEFINE_MESSAGE(WM_USERCHANGED), + DEFINE_MESSAGE(WM_NOTIFYFORMAT), + + DEFINE_MESSAGE(WM_CONTEXTMENU), + DEFINE_MESSAGE(WM_STYLECHANGING), + DEFINE_MESSAGE(WM_STYLECHANGED), + DEFINE_MESSAGE(WM_DISPLAYCHANGE), + DEFINE_MESSAGE(WM_GETICON), + DEFINE_MESSAGE(WM_SETICON), +# endif /* WINVER >= 0x0400 */ + + DEFINE_MESSAGE(WM_NCCREATE), + DEFINE_MESSAGE(WM_NCDESTROY), + DEFINE_MESSAGE(WM_NCCALCSIZE), + DEFINE_MESSAGE(WM_NCHITTEST), + DEFINE_MESSAGE(WM_NCPAINT), + DEFINE_MESSAGE(WM_NCACTIVATE), + DEFINE_MESSAGE(WM_GETDLGCODE), +# ifndef _WIN32_WCE + DEFINE_MESSAGE(WM_SYNCPAINT), +# endif + DEFINE_MESSAGE(WM_NCMOUSEMOVE), + DEFINE_MESSAGE(WM_NCLBUTTONDOWN), + DEFINE_MESSAGE(WM_NCLBUTTONUP), + DEFINE_MESSAGE(WM_NCLBUTTONDBLCLK), + DEFINE_MESSAGE(WM_NCRBUTTONDOWN), + DEFINE_MESSAGE(WM_NCRBUTTONUP), + DEFINE_MESSAGE(WM_NCRBUTTONDBLCLK), + DEFINE_MESSAGE(WM_NCMBUTTONDOWN), + DEFINE_MESSAGE(WM_NCMBUTTONUP), + DEFINE_MESSAGE(WM_NCMBUTTONDBLCLK), + + + +# if(_WIN32_WINNT >= 0x0500) + DEFINE_MESSAGE(WM_NCXBUTTONDOWN), + DEFINE_MESSAGE(WM_NCXBUTTONUP), + DEFINE_MESSAGE(WM_NCXBUTTONDBLCLK), +# endif /* _WIN32_WINNT >= 0x0500 */ + + +# if(_WIN32_WINNT >= 0x0501) + DEFINE_MESSAGE(WM_INPUT_DEVICE_CHANGE), +# endif /* _WIN32_WINNT >= 0x0501 */ + +# if(_WIN32_WINNT >= 0x0501) + DEFINE_MESSAGE(WM_INPUT), +# endif /* _WIN32_WINNT >= 0x0501 */ + + DEFINE_MESSAGE(WM_KEYDOWN), + DEFINE_MESSAGE(WM_KEYUP), + DEFINE_MESSAGE(WM_CHAR), + DEFINE_MESSAGE(WM_DEADCHAR), + DEFINE_MESSAGE(WM_SYSKEYDOWN), + DEFINE_MESSAGE(WM_SYSKEYUP), + DEFINE_MESSAGE(WM_SYSCHAR), + DEFINE_MESSAGE(WM_SYSDEADCHAR), +# if(_WIN32_WINNT >= 0x0501) + DEFINE_MESSAGE(WM_UNICHAR), +# endif /* _WIN32_WINNT >= 0x0501 */ + +# if(WINVER >= 0x0400) + DEFINE_MESSAGE(WM_IME_STARTCOMPOSITION), + DEFINE_MESSAGE(WM_IME_ENDCOMPOSITION), + DEFINE_MESSAGE(WM_IME_COMPOSITION), + DEFINE_MESSAGE(WM_IME_KEYLAST), +# endif /* WINVER >= 0x0400 */ + + DEFINE_MESSAGE(WM_INITDIALOG), + DEFINE_MESSAGE(WM_COMMAND), + DEFINE_MESSAGE(WM_SYSCOMMAND), + DEFINE_MESSAGE(WM_TIMER), + DEFINE_MESSAGE(WM_HSCROLL), + DEFINE_MESSAGE(WM_VSCROLL), + DEFINE_MESSAGE(WM_INITMENU), + DEFINE_MESSAGE(WM_INITMENUPOPUP), +# if(WINVER >= 0x0601) + DEFINE_MESSAGE(WM_GESTURE), + DEFINE_MESSAGE(WM_GESTURENOTIFY), +# endif /* WINVER >= 0x0601 */ + DEFINE_MESSAGE(WM_MENUSELECT), + DEFINE_MESSAGE(WM_MENUCHAR), + DEFINE_MESSAGE(WM_ENTERIDLE), +# if(WINVER >= 0x0500) +# ifndef _WIN32_WCE + DEFINE_MESSAGE(WM_MENURBUTTONUP), + DEFINE_MESSAGE(WM_MENUDRAG), + DEFINE_MESSAGE(WM_MENUGETOBJECT), + DEFINE_MESSAGE(WM_UNINITMENUPOPUP), + DEFINE_MESSAGE(WM_MENUCOMMAND), + +# if(_WIN32_WINNT >= 0x0500) + DEFINE_MESSAGE(WM_CHANGEUISTATE), + DEFINE_MESSAGE(WM_UPDATEUISTATE), + DEFINE_MESSAGE(WM_QUERYUISTATE), +# endif /* _WIN32_WINNT >= 0x0500 */ + +# endif +# endif /* WINVER >= 0x0500 */ + + DEFINE_MESSAGE(WM_CTLCOLORMSGBOX), + DEFINE_MESSAGE(WM_CTLCOLOREDIT), + DEFINE_MESSAGE(WM_CTLCOLORLISTBOX), + DEFINE_MESSAGE(WM_CTLCOLORBTN), + DEFINE_MESSAGE(WM_CTLCOLORDLG), + DEFINE_MESSAGE(WM_CTLCOLORSCROLLBAR), + DEFINE_MESSAGE(WM_CTLCOLORSTATIC), +# define MN_GETHMENU 0x01E1 + + DEFINE_MESSAGE(WM_MOUSEMOVE), + DEFINE_MESSAGE(WM_LBUTTONDOWN), + DEFINE_MESSAGE(WM_LBUTTONUP), + DEFINE_MESSAGE(WM_LBUTTONDBLCLK), + DEFINE_MESSAGE(WM_RBUTTONDOWN), + DEFINE_MESSAGE(WM_RBUTTONUP), + DEFINE_MESSAGE(WM_RBUTTONDBLCLK), + DEFINE_MESSAGE(WM_MBUTTONDOWN), + DEFINE_MESSAGE(WM_MBUTTONUP), + DEFINE_MESSAGE(WM_MBUTTONDBLCLK), +# if (_WIN32_WINNT >= 0x0400) || (_WIN32_WINDOWS > 0x0400) + DEFINE_MESSAGE(WM_MOUSEWHEEL), +# endif +# if (_WIN32_WINNT >= 0x0500) + DEFINE_MESSAGE(WM_XBUTTONDOWN), + DEFINE_MESSAGE(WM_XBUTTONUP), + DEFINE_MESSAGE(WM_XBUTTONDBLCLK), +# endif +# if (_WIN32_WINNT >= 0x0600) + DEFINE_MESSAGE(WM_MOUSEHWHEEL), +# endif + + + + DEFINE_MESSAGE(WM_PARENTNOTIFY), + DEFINE_MESSAGE(WM_ENTERMENULOOP), + DEFINE_MESSAGE(WM_EXITMENULOOP), + +# if(WINVER >= 0x0400) + DEFINE_MESSAGE(WM_NEXTMENU), + DEFINE_MESSAGE(WM_SIZING), + DEFINE_MESSAGE(WM_CAPTURECHANGED), + DEFINE_MESSAGE(WM_MOVING), +# endif /* WINVER >= 0x0400 */ + +# if(WINVER >= 0x0400) + DEFINE_MESSAGE(WM_POWERBROADCAST), + DEFINE_MESSAGE(WM_DEVICECHANGE), +# endif /* WINVER >= 0x0400 */ + + DEFINE_MESSAGE(WM_MDICREATE), + DEFINE_MESSAGE(WM_MDIDESTROY), + DEFINE_MESSAGE(WM_MDIACTIVATE), + DEFINE_MESSAGE(WM_MDIRESTORE), + DEFINE_MESSAGE(WM_MDINEXT), + DEFINE_MESSAGE(WM_MDIMAXIMIZE), + DEFINE_MESSAGE(WM_MDITILE), + DEFINE_MESSAGE(WM_MDICASCADE), + DEFINE_MESSAGE(WM_MDIICONARRANGE), + DEFINE_MESSAGE(WM_MDIGETACTIVE), + + + DEFINE_MESSAGE(WM_MDISETMENU), + DEFINE_MESSAGE(WM_ENTERSIZEMOVE), + DEFINE_MESSAGE(WM_EXITSIZEMOVE), + DEFINE_MESSAGE(WM_DROPFILES), + DEFINE_MESSAGE(WM_MDIREFRESHMENU), + +# if(WINVER >= 0x0602) + DEFINE_MESSAGE(WM_POINTERDEVICECHANGE), + DEFINE_MESSAGE(WM_POINTERDEVICEINRANGE), + DEFINE_MESSAGE(WM_POINTERDEVICEOUTOFRANGE), +# endif /* WINVER >= 0x0602 */ + +# if(WINVER >= 0x0601) + DEFINE_MESSAGE(WM_TOUCH), +# endif /* WINVER >= 0x0601 */ + +# if(WINVER >= 0x0602) + DEFINE_MESSAGE(WM_NCPOINTERUPDATE), + DEFINE_MESSAGE(WM_NCPOINTERDOWN), + DEFINE_MESSAGE(WM_NCPOINTERUP), + DEFINE_MESSAGE(WM_POINTERUPDATE), + DEFINE_MESSAGE(WM_POINTERDOWN), + DEFINE_MESSAGE(WM_POINTERUP), + DEFINE_MESSAGE(WM_POINTERENTER), + DEFINE_MESSAGE(WM_POINTERLEAVE), + DEFINE_MESSAGE(WM_POINTERACTIVATE), + DEFINE_MESSAGE(WM_POINTERCAPTURECHANGED), + DEFINE_MESSAGE(WM_TOUCHHITTESTING), + DEFINE_MESSAGE(WM_POINTERWHEEL), + DEFINE_MESSAGE(WM_POINTERHWHEEL), +# endif /* WINVER >= 0x0602 */ + + +# if(WINVER >= 0x0400) + DEFINE_MESSAGE(WM_IME_SETCONTEXT), + DEFINE_MESSAGE(WM_IME_NOTIFY), + DEFINE_MESSAGE(WM_IME_CONTROL), + DEFINE_MESSAGE(WM_IME_COMPOSITIONFULL), + DEFINE_MESSAGE(WM_IME_SELECT), + DEFINE_MESSAGE(WM_IME_CHAR), +# endif /* WINVER >= 0x0400 */ +# if(WINVER >= 0x0500) + DEFINE_MESSAGE(WM_IME_REQUEST), +# endif /* WINVER >= 0x0500 */ +# if(WINVER >= 0x0400) + DEFINE_MESSAGE(WM_IME_KEYDOWN), + DEFINE_MESSAGE(WM_IME_KEYUP), +# endif /* WINVER >= 0x0400 */ + +# if((_WIN32_WINNT >= 0x0400) || (WINVER >= 0x0500)) + DEFINE_MESSAGE(WM_MOUSEHOVER), + DEFINE_MESSAGE(WM_MOUSELEAVE), +# endif +# if(WINVER >= 0x0500) + DEFINE_MESSAGE(WM_NCMOUSEHOVER), + DEFINE_MESSAGE(WM_NCMOUSELEAVE), +# endif /* WINVER >= 0x0500 */ + +# if(_WIN32_WINNT >= 0x0501) + DEFINE_MESSAGE(WM_WTSSESSION_CHANGE), +# endif /* _WIN32_WINNT >= 0x0501 */ + + DEFINE_MESSAGE(WM_CUT), + DEFINE_MESSAGE(WM_COPY), + DEFINE_MESSAGE(WM_PASTE), + DEFINE_MESSAGE(WM_CLEAR), + DEFINE_MESSAGE(WM_UNDO), + DEFINE_MESSAGE(WM_RENDERFORMAT), + DEFINE_MESSAGE(WM_RENDERALLFORMATS), + DEFINE_MESSAGE(WM_DESTROYCLIPBOARD), + DEFINE_MESSAGE(WM_DRAWCLIPBOARD), + DEFINE_MESSAGE(WM_PAINTCLIPBOARD), + DEFINE_MESSAGE(WM_VSCROLLCLIPBOARD), + DEFINE_MESSAGE(WM_SIZECLIPBOARD), + DEFINE_MESSAGE(WM_ASKCBFORMATNAME), + DEFINE_MESSAGE(WM_CHANGECBCHAIN), + DEFINE_MESSAGE(WM_HSCROLLCLIPBOARD), + DEFINE_MESSAGE(WM_QUERYNEWPALETTE), + DEFINE_MESSAGE(WM_PALETTEISCHANGING), + DEFINE_MESSAGE(WM_PALETTECHANGED), + DEFINE_MESSAGE(WM_HOTKEY), + +# if(WINVER >= 0x0400) + DEFINE_MESSAGE(WM_PRINT), + DEFINE_MESSAGE(WM_PRINTCLIENT), +# endif /* WINVER >= 0x0400 */ + +# if(_WIN32_WINNT >= 0x0500) + DEFINE_MESSAGE(WM_APPCOMMAND), +# endif /* _WIN32_WINNT >= 0x0500 */ + +# if(_WIN32_WINNT >= 0x0501) + DEFINE_MESSAGE(WM_THEMECHANGED), +# endif /* _WIN32_WINNT >= 0x0501 */ + + +# if(_WIN32_WINNT >= 0x0501) + DEFINE_MESSAGE(WM_CLIPBOARDUPDATE), +# endif /* _WIN32_WINNT >= 0x0501 */ + +# if(_WIN32_WINNT >= 0x0600) + DEFINE_MESSAGE(WM_DWMCOMPOSITIONCHANGED), + DEFINE_MESSAGE(WM_DWMNCRENDERINGCHANGED), + DEFINE_MESSAGE(WM_DWMCOLORIZATIONCOLORCHANGED), + DEFINE_MESSAGE(WM_DWMWINDOWMAXIMIZEDCHANGE), +# endif /* _WIN32_WINNT >= 0x0600 */ + +# if(_WIN32_WINNT >= 0x0601) + DEFINE_MESSAGE(WM_DWMSENDICONICTHUMBNAIL), + DEFINE_MESSAGE(WM_DWMSENDICONICLIVEPREVIEWBITMAP), +# endif /* _WIN32_WINNT >= 0x0601 */ + + +# if(WINVER >= 0x0600) + DEFINE_MESSAGE(WM_GETTITLEBARINFOEX), +# endif /* WINVER >= 0x0600 */ + { 0, NULL, } /* end of message list */ +}; +#undef DEFINE_MESSAGE + +char* WMMsg2Str(DWORD dwMessage) +{ + struct WM_MESSAGE_MAP* pMapMsg = allMessages; + for (/*null*/; pMapMsg->lpszMsg != NULL; pMapMsg++) + { + if (pMapMsg->nMsg == dwMessage ) + { + return (char *)pMapMsg->lpszMsg; + } + } + return ""; +} +#endif /* _DEBUG */ + + /* Get system time, taking special precautions against 32bit timer wrap. We use timeGetTime and not GetTickCount because of its better stability, and because we can increase its granularity (to 1 ms in @@ -395,8 +778,8 @@ if ( ( window == NULL ) && ( uMsg != WM_CREATE ) ) return DefWindowProc( hWnd, uMsg, wParam, lParam ); - /* printf ( "Window %3d message <%04x> %12d %12d\n", window?window->ID:0, - uMsg, wParam, lParam ); */ + /* printf ( "Window %3d message %s (<%04x>) %12d %12d\n", window?window->ID:0, + WMMsg2Str(uMsg), uMsg, wParam, lParam ); */ switch( uMsg ) { This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <dcnieho@us...> - 2013-04-06 10:15:28
|
Revision: 1607 http://freeglut.svn.sourceforge.net/freeglut/?rev=1607&view=rev Author: dcnieho Date: 2013-04-06 10:15:19 +0000 (Sat, 06 Apr 2013) Log Message: ----------- now handling WM_MOUSEACTIVATE so that menus don't get activated upon mouseclick Modified Paths: -------------- trunk/freeglut/freeglut/src/mswin/fg_internal_mswin.h trunk/freeglut/freeglut/src/mswin/fg_main_mswin.c Modified: trunk/freeglut/freeglut/src/mswin/fg_internal_mswin.h =================================================================== --- trunk/freeglut/freeglut/src/mswin/fg_internal_mswin.h 2013-04-06 10:14:41 UTC (rev 1606) +++ trunk/freeglut/freeglut/src/mswin/fg_internal_mswin.h 2013-04-06 10:15:19 UTC (rev 1607) @@ -96,7 +96,7 @@ DWORD OldStyleEx; /* window Ex style - stored before the window is made fullscreen */ BOOL OldMaximized; /* window maximized state - stored before the window is made fullscreen */ - GLboolean MouseTracking; /* Needed for generating GLUT_ENTERED and GLUT_LEFT entry func callbacks on windows */ + BOOL MouseTracking; /* Needed for generating GLUT_ENTERED and GLUT_LEFT entry func callbacks on windows */ /* Need to store window titles to emulate * glutSetIconTitle/glutSetWindowTitle as Windows has only Modified: trunk/freeglut/freeglut/src/mswin/fg_main_mswin.c =================================================================== --- trunk/freeglut/freeglut/src/mswin/fg_main_mswin.c 2013-04-06 10:14:41 UTC (rev 1606) +++ trunk/freeglut/freeglut/src/mswin/fg_main_mswin.c 2013-04-06 10:15:19 UTC (rev 1607) @@ -589,9 +589,20 @@ fgPlatformCheckMenuDeactivate(); break; + case WM_MOUSEACTIVATE: + /* Clicks should not activate the menu. + * Especially important when clicking on a menu's submenu item which has no effect. + */ + printf("WM_MOUSEACTIVATE\n"); + if (window->IsMenu) + lRet = MA_NOACTIVATEANDEAT; + else + lRet = DefWindowProc( hWnd, uMsg, wParam, lParam ); + break; + #if 0 case WM_ACTIVATE: - //printf("WM_ACTIVATE: %x (ID: %i) %d %d\n",lParam, window->ID, HIWORD(wParam), LOWORD(wParam)); + /* printf("WM_ACTIVATE: %x (ID: %i) %d %d\n",lParam, window->ID, HIWORD(wParam), LOWORD(wParam)); */ if (LOWORD(wParam) != WA_INACTIVE) { /* printf("WM_ACTIVATE: fgSetCursor( %p, %d)\n", window, @@ -629,7 +640,7 @@ tme.hwndTrack = window->Window.Handle; TrackMouseEvent(&tme); - window->State.pWState.MouseTracking = GL_TRUE; + window->State.pWState.MouseTracking = TRUE; } } } @@ -648,7 +659,7 @@ INVOKE_WCB( *window, Entry, ( GLUT_LEFT ) ); fgSetWindow(saved_window); - window->State.pWState.MouseTracking = GL_FALSE; + window->State.pWState.MouseTracking = FALSE; lRet = 0; /* As per docs, must return zero */ } break; This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <dcnieho@us...> - 2013-04-06 10:14:52
|
Revision: 1606 http://freeglut.svn.sourceforge.net/freeglut/?rev=1606&view=rev Author: dcnieho Date: 2013-04-06 10:14:41 +0000 (Sat, 06 Apr 2013) Log Message: ----------- fix in fgUpdateMenuHighlight: clicked entry is always the active entry already, so no while loop. also, ignore clicks on a submenu's parent entry Modified Paths: -------------- trunk/freeglut/freeglut/src/fg_menu.c Modified: trunk/freeglut/freeglut/src/fg_menu.c =================================================================== --- trunk/freeglut/freeglut/src/fg_menu.c 2013-04-05 13:40:32 UTC (rev 1605) +++ trunk/freeglut/freeglut/src/fg_menu.c 2013-04-06 10:14:41 UTC (rev 1606) @@ -265,7 +265,7 @@ } /* Activate it because its parent entry is active */ - menuEntry->SubMenu->IsActive = GL_TRUE; /* XXX Do we need this? */ + menuEntry->SubMenu->IsActive = GL_TRUE; } /* Report back that we have caught the menu cursor */ @@ -546,8 +546,7 @@ /* * Update Highlight states of the menu - * - * Current mouse position is in menu->Window->State.MouseX/Y. + * NB: Current mouse position is in menu->Window->State.MouseX/Y */ void fgUpdateMenuHighlight ( SFG_Menu *menu ) { @@ -597,28 +596,25 @@ * window to the window whose menu this is */ SFG_Window *save_window = fgStructure.CurrentWindow; - SFG_Menu *save_menu = fgStructure.CurrentMenu, *active_menu = window->ActiveMenu; - SFG_MenuEntry *active_entry = active_menu->ActiveEntry; + SFG_Menu *save_menu = fgStructure.CurrentMenu, *active_menu = window->ActiveMenu; /* active menu is always the one with the mouse in it, due to fghCheckMenuStatus */ + SFG_MenuEntry *active_entry = active_menu->ActiveEntry; /* currently highlighted item -> must be the one that was just clicked */ SFG_Window *parent_window = window->ActiveMenu->ParentWindow; - /* get clicked entry */ - while (active_entry->SubMenu) + /* ignore clicks on the submenu entry */ + if (!active_entry->SubMenu) { - active_menu = active_entry->SubMenu; - active_entry = active_menu->ActiveEntry; - } + fgSetWindow( parent_window ); + fgStructure.CurrentMenu = active_menu; - fgSetWindow( parent_window ); - fgStructure.CurrentMenu = active_menu; + /* Deactivate menu and then call callback (we don't want menu to stay in view while callback is executing) */ + fgDeactivateMenu( parent_window ); + active_menu->Callback( active_entry->ID ); - /* Deactivate menu and then call callback (we don't want menu to stay in view while callback is executing) */ - fgDeactivateMenu( parent_window ); - active_menu->Callback( active_entry->ID ); + /* Restore the current window and menu */ + fgSetWindow( save_window ); + fgStructure.CurrentMenu = save_menu; + } - /* Restore the current window and menu */ - fgSetWindow( save_window ); - fgStructure.CurrentMenu = save_menu; - is_clicked = GL_TRUE; /* Don't reopen... */ } else if( pressed ) @@ -748,9 +744,9 @@ /* * If the entry is a submenu, then it needs to be wider to - * accomodate the arrow. JCJ 31 July 2003 + * accommodate the arrow. */ - if (menuEntry->SubMenu ) + if (menuEntry->SubMenu) menuEntry->Width += glutBitmapLength( fgStructure.CurrentMenu->Font, (unsigned char *)"_" This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |