Implemented basic timeout functionality for buttons