Better button handling