diff --git a/src/extensibility/ExtensionManager.js b/src/extensibility/ExtensionManager.js index b3ec07fb0..834011dbf 100644 --- a/src/extensibility/ExtensionManager.js +++ b/src/extensibility/ExtensionManager.js @@ -49,6 +49,7 @@ define(function (require, exports, module) { Strings = require("strings"), StringUtils = require("utils/StringUtils"), ThemeManager = require("view/ThemeManager"), + TaskManager = require("features/TaskManager"), Metrics = require("utils/Metrics"); const EXTENSION_REGISTRY_LOCAL_STORAGE_KEY = Phoenix.isTestWindow ? @@ -355,6 +356,9 @@ define(function (require, exports, module) { function _updateRegistry(newVersion) { console.log("downloading extension registry: ", newVersion, brackets.config.extension_registry); + const downloadTask = TaskManager.addNewTask(Strings.EXTENSIONS_REGISTRY_TASK_TITLE, + Strings.EXTENSIONS_REGISTRY_TASK_MESSAGE, + ``); $.ajax({ url: brackets.config.extension_registry, dataType: "json", @@ -371,9 +375,11 @@ define(function (require, exports, module) { } }).finally(()=>{ pendingDownloadRegistry = null; + downloadTask.close(); }); }) .fail(function (err) { + downloadTask.close(); console.error("error Fetching Extension Registry", err); if(!pendingDownloadRegistry.alreadyResolvedFromCache){ pendingDownloadRegistry.reject(); diff --git a/src/nls/root/strings.js b/src/nls/root/strings.js index 6fe351209..ee071f557 100644 --- a/src/nls/root/strings.js +++ b/src/nls/root/strings.js @@ -811,6 +811,8 @@ define({ "EXTENSIONS_UPDATES_TITLE": "Updates", "EXTENSIONS_LAST_UPDATED": "Last Updated", "EXTENSIONS_DOWNLOADS": "Downloads", + "EXTENSIONS_REGISTRY_TASK_TITLE": "Updating Extension List", + "EXTENSIONS_REGISTRY_TASK_MESSAGE": "Downloading\u2026", "INLINE_EDITOR_NO_MATCHES": "No matches available.", "INLINE_EDITOR_HIDDEN_MATCHES": "All matches are collapsed. Expand the files listed at right to view matches.",