| Index: chrome/browser/resources/chromeos/chromevox/chromevox/injected/script_installer.js
|
| diff --git a/chrome/browser/resources/chromeos/chromevox/chromevox/injected/script_installer.js b/chrome/browser/resources/chromeos/chromevox/chromevox/injected/script_installer.js
|
| index 471039b363ad2301400cd1d91693a967428e73f2..cf7b2f8f946532fccdc6f7808192008181b912c1 100644
|
| --- a/chrome/browser/resources/chromeos/chromevox/chromevox/injected/script_installer.js
|
| +++ b/chrome/browser/resources/chromeos/chromevox/chromevox/injected/script_installer.js
|
| @@ -29,8 +29,8 @@ cvox.ScriptInstaller.blacklistPattern = /chrome:\/\/|chrome-extension:\/\//;
|
| * @return {boolean} False if the script already existed and this function
|
| * didn't do anything.
|
| */
|
| -cvox.ScriptInstaller.installScript = function(srcs, uid, opt_onload,
|
| - opt_chromevoxScriptBase) {
|
| +cvox.ScriptInstaller.installScript = function(
|
| + srcs, uid, opt_onload, opt_chromevoxScriptBase) {
|
| if (cvox.ScriptInstaller.blacklistPattern.test(document.URL)) {
|
| return false;
|
| }
|
| @@ -41,8 +41,8 @@ cvox.ScriptInstaller.installScript = function(srcs, uid, opt_onload,
|
| return false;
|
| }
|
|
|
| - cvox.ScriptInstaller.installScriptHelper_(srcs, uid, opt_onload,
|
| - opt_chromevoxScriptBase);
|
| + cvox.ScriptInstaller.installScriptHelper_(
|
| + srcs, uid, opt_onload, opt_chromevoxScriptBase);
|
| return true;
|
| };
|
|
|
| @@ -58,12 +58,12 @@ cvox.ScriptInstaller.installScript = function(srcs, uid, opt_onload,
|
| * attribute to add.
|
| * @private
|
| */
|
| -cvox.ScriptInstaller.installScriptHelper_ = function(srcs, uid, opt_onload,
|
| - opt_chromevoxScriptBase) {
|
| +cvox.ScriptInstaller.installScriptHelper_ = function(
|
| + srcs, uid, opt_onload, opt_chromevoxScriptBase) {
|
| function next() {
|
| if (srcs.length > 0) {
|
| - cvox.ScriptInstaller.installScriptHelper_(srcs, uid, opt_onload,
|
| - opt_chromevoxScriptBase);
|
| + cvox.ScriptInstaller.installScriptHelper_(
|
| + srcs, uid, opt_onload, opt_chromevoxScriptBase);
|
| } else if (opt_onload) {
|
| opt_onload();
|
| }
|
| @@ -89,8 +89,7 @@ cvox.ScriptInstaller.installScriptHelper_ = function(srcs, uid, opt_onload,
|
| apiScript.setAttribute(uid, '1');
|
| apiScript.textContent = scriptText;
|
| if (opt_chromevoxScriptBase) {
|
| - apiScript.setAttribute('chromevoxScriptBase',
|
| - opt_chromevoxScriptBase);
|
| + apiScript.setAttribute('chromevoxScriptBase', opt_chromevoxScriptBase);
|
| }
|
| var scriptOwner = document.head || document.body;
|
| scriptOwner.appendChild(apiScript);
|
| @@ -102,8 +101,9 @@ cvox.ScriptInstaller.installScriptHelper_ = function(srcs, uid, opt_onload,
|
| xhr.open('GET', url, true);
|
| xhr.send(null);
|
| } catch (exception) {
|
| - console.log('Warning: ChromeVox external script loading for ' +
|
| - document.location + ' stopped after failing to install ' + scriptSrc);
|
| + console.log(
|
| + 'Warning: ChromeVox external script loading for ' + document.location +
|
| + ' stopped after failing to install ' + scriptSrc);
|
| next();
|
| }
|
| };
|
|
|