Chromium Code Reviews| Index: chrome/browser/resources/chromeos/chromevox/cvox2/background/background.js |
| diff --git a/chrome/browser/resources/chromeos/chromevox/cvox2/background/background.js b/chrome/browser/resources/chromeos/chromevox/cvox2/background/background.js |
| index 1a68453e3f4eda41d6891077bf96069dd5c2b48c..c402278f4060beaa0715ca41b5fa301eea627c92 100644 |
| --- a/chrome/browser/resources/chromeos/chromevox/cvox2/background/background.js |
| +++ b/chrome/browser/resources/chromeos/chromevox/cvox2/background/background.js |
| @@ -375,8 +375,7 @@ Background.prototype = { |
| } |
| break; |
| case 'showOptionsPage': |
| - var optionsPage = {url: 'chromevox/background/options.html'}; |
| - chrome.tabs.create(optionsPage); |
| + this.showOptionsPage(); |
| break; |
| case 'toggleChromeVoxVersion': |
| var newMode; |
| @@ -434,6 +433,14 @@ Background.prototype = { |
| }, |
| /** |
| + * Open the options page in a new tab. |
| + */ |
| + showOptionsPage: function() { |
| + var optionsPage = {url: 'chromevox/background/options.html'}; |
| + chrome.tabs.create(optionsPage); |
|
Peter Lundblad
2015/11/06 15:00:58
Just since you touch this, is chrome.runtime.openO
dmazzoni
2015/11/06 21:01:00
Thanks. Works great, but only if you call it from
|
| + }, |
| + |
| + /** |
| * Handles a braille command. |
| * @param {!cvox.BrailleKeyEvent} evt |
| * @param {!cvox.NavBraille} content |