mirror of
https://github.com/chinchang/web-maker.git
synced 2025-06-21 23:12:19 +02:00
fallback to old method of options page bcoz of bug.
This commit is contained in:
@ -211,12 +211,17 @@
|
|||||||
});
|
});
|
||||||
|
|
||||||
settingsBtn.addEventListener('click', function(e) {
|
settingsBtn.addEventListener('click', function(e) {
|
||||||
if (chrome.runtime.openOptionsPage) {
|
if (!chrome.runtime.openOptionsPage) {
|
||||||
// New way to open options pages, if supported (Chrome 42+).
|
// New way to open options pages, if supported (Chrome 42+).
|
||||||
|
// Bug: https://bugs.chromium.org/p/chromium/issues/detail?id=601997
|
||||||
|
// Until this bug fixes, use the
|
||||||
|
// fallback.
|
||||||
chrome.runtime.openOptionsPage();
|
chrome.runtime.openOptionsPage();
|
||||||
} else {
|
} else {
|
||||||
// Fallback.
|
// Fallback.
|
||||||
window.open(chrome.runtime.getURL('options.html'));
|
chrome.tabs.create({
|
||||||
|
url: 'chrome://extensions?options=' + chrome.i18n.getMessage('@@extension_id')
|
||||||
|
});
|
||||||
}
|
}
|
||||||
return false;
|
return false;
|
||||||
});
|
});
|
||||||
|
Reference in New Issue
Block a user