-
-
Notifications
You must be signed in to change notification settings - Fork 630
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add ability to specify add-on store metadata URL from within NVDA (#1…
…7099) Closes #14974 Summary of the issue: The add-on store metadata URL is currently hard-coded in NVDA. This presents problems for users who are unable to use the default URL for any reason. This particularly affects users in the People's Republic of China, many of whom are unable to access the add-on store at an acceptable speed. A community add-on exists to work around this, but a means of specifying a mirror directly within NVDA is considered a better approach. Description of user facing changes Added a text box in Add-on store settings that allows users to specify the URL to use for the add-on store. Added slightly more helpful wording to add-on store errors that encourages users to check the metadata URL if there are issues accessing the add-on store and a custom URL is in use. Description of development approach Added a config key, `addonStore.baseURL`, to hold the URL of the server to contact for add-on store data. Added a control to the settings dialog that is populated by and populates this config item. Removed `addonStore.BASE_URL` in favour of a private constant which holds the default base URL. Added a private function, `addonStore.network._getBaseURL`, which gets the custom URL if one is set, or the default otherwise. Modified `addonStore.dataManager`, refactoring the `DisplayableError` code into a helper function and adding some troubleshooting steps to the messages that NVDA shows when showing errors. Testing strategy: Tested accessing the add-on store with no mirror set, with an invalid mirror set, and with no internet access. Known issues with pull request: The settings dialog makes a best effort at normalizing the URL. However, URLs with incompatible protocols or other issues that will cause them to fail with the Add-on Store are not checked for. Users will see a message asking them to check the mirror URL if contacting the store fails and a mirror is in use.
- Loading branch information
1 parent
c87aaa9
commit f38e623
Showing
7 changed files
with
85 additions
and
15 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters