set up menus leading from main --> mode --> settings and back again, fixed the bug where buttons would pop up more than once, and fixed the problem with multiple windows being open at the same time