Separate button sensing into another file