reworking button press code to support double tap