Fix button events mechanism