From: Michael Tremer Date: Wed, 30 Nov 2016 17:38:54 +0000 (+0100) Subject: ui.progressbar: Rename update_increment method to increment X-Git-Tag: 0.9.28~1285^2~1452 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=914d9ab0d408cdc30e9ed341c3ef8a12833753e8;p=pakfire.git ui.progressbar: Rename update_increment method to increment Signed-off-by: Michael Tremer --- diff --git a/src/pakfire/http.py b/src/pakfire/http.py index 0964c118f..3b51d29b2 100644 --- a/src/pakfire/http.py +++ b/src/pakfire/http.py @@ -227,7 +227,7 @@ class Client(object): break l = len(buf) - p.update_increment(l) + p.increment(l) def _get_content_length(self, response): s = response.getheader("Content-Length") diff --git a/src/pakfire/hub.py b/src/pakfire/hub.py index 4dd26f5ff..ca71dd254 100644 --- a/src/pakfire/hub.py +++ b/src/pakfire/hub.py @@ -218,7 +218,7 @@ class FileUploader(object): chunk_size = CHUNK_SIZE # Update progressbar - p.update_increment(len(chunk)) + p.increment(len(chunk)) # Catch any unhandled exception here, tell the hub to delete the # file and raise the original exception diff --git a/src/pakfire/ui/progressbar.py b/src/pakfire/ui/progressbar.py index ecb241524..8805ed362 100644 --- a/src/pakfire/ui/progressbar.py +++ b/src/pakfire/ui/progressbar.py @@ -98,7 +98,7 @@ class ProgressBar(object): self.fd.write(self._format_line()) self.fd.write("\r") - def update_increment(self, value): + def increment(self, value): return self.update(self.value_cur + value) def _need_update(self):