def on_runtime_check(self, *args, **kwargs): self.progressbar.pulse() if not runtime.is_updating(): self.response(Gtk.ResponseType.OK) self.destroy() return False return True
def prelaunch(self): """Verify that the current game can be launched.""" if not self.runner.is_installed(): installed = self.runner.install_dialog() if not installed: return False if self.runner.use_runtime(): if runtime.is_updating(): logger.error("Runtime currently updating") result = dialogs.RuntimeUpdateDialog().run() if not result == Gtk.ResponseType.OK: return False return True
def run(self, *args): """Run the runner alone.""" if not self.runnable_alone: return if not self.is_installed(): installed = self.install_dialog() if not installed: return if self.use_runtime(): if runtime.is_outdated() or runtime.is_updating(): result = dialogs.RuntimeUpdateDialog().run() if not result == Gtk.ResponseType.OK: return command_data = self.get_run_data() command = command_data.get('command') env = (command_data.get('env') or {}).copy() if self.use_runtime(): env.update(runtime.get_env()) thread = LutrisThread(command, runner=self, env=env, watch=False) thread.start()