removed the need for RTTI/runtime type checking/dynamic_cast in glui. It is unnecessary to overhaul the build systems just for this feature. Replaced by upcasting virtual methods
if ( !dynamic_cast<GLUI_Rollout*>(this) && becomes if ( !this->dynamicCastGLUI_Rollout() && etc.
This commit is contained in:
@@ -283,7 +283,7 @@ static void listbox_callback( int i )
|
||||
int old_val;
|
||||
|
||||
if ( NOT GLUI_Master.curr_left_button_glut_menu OR
|
||||
!dynamic_cast<GLUI_Listbox*>(GLUI_Master.curr_left_button_glut_menu) )
|
||||
!GLUI_Master.curr_left_button_glut_menu->dynamicCastGLUI_Listbox() )
|
||||
return;
|
||||
|
||||
old_val = ((GLUI_Listbox*)GLUI_Master.curr_left_button_glut_menu)->int_val;
|
||||
|
||||
Reference in New Issue
Block a user