GtkWidget *widget[10];
GtkWidget *widget[sizeof(myTab)/sizeof(myVideoCodec)];
uint8_t DIA_videoCodec( SelectCodecType *codec ){	uint8_t ret=0;	SelectCodecType old=*codec;	GtkWidget *widget[10];	dialog=create_dialogVideoCodec();	//gtk_transient(dialog);		gtk_register_dialog(dialog);		// now set the input one	for(uint32_t i=0;i<sizeof(myTab)/sizeof(myVideoCodec);i++)	{		widget[i]=gtk_menu_item_new_with_mnemonic (myTab[i].name);  		gtk_widget_show (widget[i]);  		gtk_container_add (GTK_CONTAINER (WID(menu1)), widget[i]);		if(*codec==myTab[i].codec)			{				// set				gtk_option_menu_set_history(GTK_OPTION_MENU(WID(optionmenu_CodecList)), i);			}	}	gtk_signal_connect(GTK_OBJECT(WID(buttonConfigure)), "clicked",		       GTK_SIGNAL_FUNC(okCallback), (void *) 0);	gtk_signal_connect(GTK_OBJECT(WID(buttonCalc)), "clicked",		       GTK_SIGNAL_FUNC(callBackCalc), (void *) 0);	if(gtk_dialog_run(GTK_DIALOG(dialog))==GTK_RESPONSE_OK)	{					*codec=findCodec();			ret=1;		}	else	{		*codec=old;	}	gtk_widget_destroy(dialog);	gtk_unregister_dialog(dialog);	return ret;} 