def _on_on_off_changed(self): if not self._shift_pressed: DeviceComponent._on_device_on_off_changed(self)