adding pressed state to buttons