fixed some minor bugs with buttons in classes