def update(self): """Run a update to refresh the package list""" self.ac = client.AptClient() t = self.ac.update_cache(exit_handler=self._on_exit) dia = AptProgressDialog(t, parent=self.window_main, terminal=False) dia.run() dia.hide() self._show_messages(t)
def update(self): """Run a update to refresh the package list""" self.ac = client.AptClient() t = self.ac.update_cache(exit_handler=self._on_exit) dia = AptProgressDialog(t, parent=self.window_main, terminal=False) dia.run() dia.hide() self._show_messages(t)
def commit(self, add, remove): """Commit a list of package adds and removes""" self.ac = client.AptClient() t = self.ac.commit_packages(list(add), [], list(remove), [], [], exit_handler=self._on_exit) dia = AptProgressDialog(t, parent=self.window_main) dia.run() dia.hide() self._show_messages(t)
def commit(self, add, remove): """Commit a list of package adds and removes""" self.ac = client.AptClient() t = self.ac.commit_packages(list(add), [], list(remove), [], [], exit_handler=self._on_exit) dia = AptProgressDialog(t, parent=self.window_main) dia.run() dia.hide() self._show_messages(t)
def perform_action(self, window_main, to_add=None, to_rm=None): self.window_main = window_main window_main.set_sensitive(False) window_main.window.set_cursor(gtk.gdk.Cursor(gtk.gdk.WATCH)) t = self.ac.commit_packages(list(to_add), [], list(to_rm), [], [], exit_handler=self._on_exit) dia = AptProgressDialog(t, parent=window_main) dia.run() dia.hide() self._show_messages(t) window_main.set_sensitive(True) window_main.window.set_cursor(None)