Moved button logic to Button class