Cleaned up main.js, simplified getting control buttons and attaching onButtonClick to them.