def METHOD_NAME(self, event):
    if event is not None:
        # Handle key or mouse selection events - e.g. click on widget or Enter.
        if isinstance(event, KeyboardEvent):
            if event.key_code in [Screen.ctrl("M"), Screen.ctrl("J"), ord(" ")]:
                event = None
        elif isinstance(event, MouseEvent):
            if event.buttons != 0:
                if self.is_mouse_over(event, include_label=False):
                    event = None
        # Create the pop-up if needed
        if event is None:
            self._child = _TimePickerPopup(self)
            self.frame.scene.add_effect(self._child)
    return event