def cleanup_timeout(self): if self._timeout > 0: GObject.source_remove(self._timeout) self._timeout = 0