glutMenuDestroyFunc (3) - Linux Manuals
glutMenuDestroyFunc: Destruction callback for menus.
NAME
glutMenuDestroyFunc - Destruction callback for menus.LIBRARY
OpenGLUT - menucallbackSYNOPSIS
In openglut.h Ft void Fn glutMenuDestroyFunc void( *callback )( void )PARAMETERS
Bf Em
This callback is
Bf Em
This callback
Bf Em
DESCRIPTION
When a menu is destroyed, OpenGLUT will call this
hook, if defined on that menu.
CAVEATS
For emphasis, we repeat: This callback does not bind to any window.
TODO
What on Earth is rationale for this feature? Menus should only be destroyed when we ask them to be destroyed, or when their window is destroyed. In the former case, we already know that the menu is being destroyed because we requested it. In the latter case, it is easy for the client to track that if they care, via window-destruction callbacks.