More work on menu. Checks to see whether functions exist before assigning delegates - delegates still aren't assigned though.