diff options
-rw-r--r-- | NEWS | 11 | ||||
-rwxr-xr-x | activity/activity.info | 2 | ||||
-rw-r--r-- | downloadmanager.py | 7 |
3 files changed, 15 insertions, 5 deletions
@@ -1,13 +1,20 @@ -79 +80 +* Update the progress of downloads less often #5449 (tomeu) -77 +79 +* Missing file for: Open an uri of type text/uri-list with browse #5080 +(erikos) + +78 * Give to the DS the ownership of the files we hand to it #5235 (tomeu) * Open an uri of type text/uri-list with browse #5080 (erikos) * Save view source to SAR/instance #5251 (erikos) * Move the profile in SAR/data #5221 (erikos) +77 + 76 * Added OLPC root CA support (marco, erikos) diff --git a/activity/activity.info b/activity/activity.info index 4d5e3f6..7c89f26 100755 --- a/activity/activity.info +++ b/activity/activity.info @@ -1,6 +1,6 @@ [Activity] name = Browse -activity_version = 79 +activity_version = 80 service_name = org.laptop.WebActivity icon = activity-web exec = sugar-activity webactivity.WebActivity -s diff --git a/downloadmanager.py b/downloadmanager.py index 07374f1..7b1af9c 100644 --- a/downloadmanager.py +++ b/downloadmanager.py @@ -48,6 +48,9 @@ DS_DBUS_SERVICE = 'org.laptop.sugar.DataStore' DS_DBUS_INTERFACE = 'org.laptop.sugar.DataStore' DS_DBUS_PATH = '/org/laptop/sugar/DataStore' +_MIN_TIME_UPDATE = 5 # In seconds +_MIN_PERCENT_UPDATE = 10 + _browser = None _temp_path = '/tmp' def init(browser, activity, temp_path): @@ -214,8 +217,8 @@ class Download: path, file_name = os.path.split(self._target_file.path) percent = (cur_self_progress * 100) / max_self_progress - if (time.time() - self._last_update_time) < 5 and \ - (percent - self._last_update_percent) < 5: + if (time.time() - self._last_update_time) < _MIN_TIME_UPDATE and \ + (percent - self._last_update_percent) < _MIN_PERCENT_UPDATE: return self._last_update_time = time.time() |