| Index: background.js |
| =================================================================== |
| --- a/background.js |
| +++ b/background.js |
| @@ -283,33 +283,6 @@ |
| refreshIconAndContextMenuForAllPages(); |
| }); |
| -/** |
| - * Opens options page or focuses an existing one, within the last focused window. |
| - * @param {Function} callback function to be called with the |
| - Page object of the options page |
| - */ |
| -function openOptions(callback) |
| -{ |
| - ext.pages.query({lastFocusedWindow: true}, function(pages) |
| - { |
| - var optionsUrl = ext.getURL("options.html"); |
| - |
| - for (var i = 0; i < pages.length; i++) |
| - { |
| - var page = pages[i]; |
| - if (page.url == optionsUrl) |
| - { |
| - page.activate(); |
| - if (callback) |
| - callback(page); |
| - return; |
| - } |
| - } |
| - |
| - ext.pages.open(optionsUrl, callback); |
| - }); |
| -} |
| - |
| function prepareNotificationIconAndPopup() |
| { |
| var animateIcon = (activeNotification.type !== "question"); |
| @@ -578,7 +551,7 @@ |
| } |
| break; |
| case "add-subscription": |
| - openOptions(function(page) |
| + ext.showOptions(function(page) |
| { |
| page.sendMessage(msg); |
| }); |