]> git.wh0rd.org - chrome-ext/tabs-backup.git/blobdiff - popup.js
migrate from localStorage to chrome.storage.local
[chrome-ext/tabs-backup.git] / popup.js
index b1d3c9cd4ee79c2ce762e10497f96c8858794869..313045e21555db2ba30232619664c27e046cd889 100644 (file)
--- a/popup.js
+++ b/popup.js
@@ -34,7 +34,7 @@ document.addEventListener('DOMContentLoaded', function () {
 });
 
 function menu_ShowOptions () {
-       chrome.tabs.create({url:chrome.extension.getURL("options.html")});
+       chrome.runtime.openOptionsPage();
 }
 
 function menu_ShowAdvancedView() {
@@ -338,16 +338,3 @@ function menu_backupNow() {
 function menu_restoreNow() {
        chrome.runtime.getBackgroundPage((bg) => bg.restoreNow('full_backup'));
 }
-
-//document.onload(function () {
-//var a = document.getElementById("myid");
-//a.innerHTML = "ciaociao";
-//});
-
-/*
-var storageLocal = chrome.storage.local;
-storageLocal.getBytesInUse(null, function(bytesInUse) {
-       var elem = document.createElement("div");
-       elem.innerHTML = "<b>BYTES IN USE: " + bytesInUse + "</b><br />";
-       document.body.appendChild(elem);
-});*/