You need to use the getPressed callback and return True or False accordingly.