Create icon for each indicating state in the toolbar(HTTPS, Bittorrent, HTTPS+Bittorrent, X-I2P-Location) with our own lock icons for .i2p sites, https .i2p sites
@@ -214,11 +214,8 @@ function themeWindow(window) {
|
||||
function logTabs(tabInfo) {
|
||||
function onContextGotTheme(context) {
|
||||
if (context.name == titlepref) {
|
||||
browserTheme();
|
||||
browser.pageAction.show(tabInfo[0].id);
|
||||
} else {
|
||||
//browser.pageAction.hide(tabInfo[0].id);
|
||||
}
|
||||
browserTheme();
|
||||
browser.pageAction.show(tabInfo[0].id);
|
||||
} else if (context.name == routerpref) {
|
||||
console.log("Active in Router Console window");
|
||||
dynamicTheme();
|
||||
@@ -373,36 +370,36 @@ function handleUpdated(updateInfo) {
|
||||
console.log("original theme found:", them, Object.keys(them).length);
|
||||
try {
|
||||
if (updateInfo.theme.colors != null) {
|
||||
console.log(
|
||||
"testing theme",
|
||||
updateInfo.theme.colors.toolbar,
|
||||
"!=",
|
||||
btheme.colors.toolbar
|
||||
);
|
||||
console.log(
|
||||
"testing theme",
|
||||
updateInfo.theme.colors.toolbar,
|
||||
"!=",
|
||||
dtheme.colors.toolbar
|
||||
);
|
||||
if (
|
||||
updateInfo.theme.colors.toolbar != dtheme.colors.toolbar &&
|
||||
updateInfo.theme.colors.toolbar != btheme.colors.toolbar
|
||||
) {
|
||||
function onSet() {
|
||||
console.log("stored theme:", updateInfo.theme);
|
||||
}
|
||||
/*if (
|
||||
console.log(
|
||||
"testing theme",
|
||||
updateInfo.theme.colors.toolbar,
|
||||
"!=",
|
||||
btheme.colors.toolbar
|
||||
);
|
||||
console.log(
|
||||
"testing theme",
|
||||
updateInfo.theme.colors.toolbar,
|
||||
"!=",
|
||||
dtheme.colors.toolbar
|
||||
);
|
||||
if (
|
||||
updateInfo.theme.colors.toolbar != dtheme.colors.toolbar &&
|
||||
updateInfo.theme.colors.toolbar != btheme.colors.toolbar
|
||||
) {
|
||||
function onSet() {
|
||||
console.log("stored theme:", updateInfo.theme);
|
||||
}
|
||||
/*if (
|
||||
updateInfo.theme.colors != null &&
|
||||
updateInfo.theme.images != null &&
|
||||
updateInfo.theme.properties != null
|
||||
) {*/
|
||||
console.log("storing theme:", updateInfo.theme);
|
||||
browser.storage.local
|
||||
.set({ originalTheme: updateInfo.theme })
|
||||
.then(onSet, onError);
|
||||
//}
|
||||
}
|
||||
console.log("storing theme:", updateInfo.theme);
|
||||
browser.storage.local
|
||||
.set({ originalTheme: updateInfo.theme })
|
||||
.then(onSet, onError);
|
||||
//}
|
||||
}
|
||||
}
|
||||
} catch (e) {
|
||||
console.log("theme storage error", e);
|
||||
|
||||
|
Before Width: | Height: | Size: 73 KiB After Width: | Height: | Size: 73 KiB |
|
Before Width: | Height: | Size: 33 KiB After Width: | Height: | Size: 32 KiB |
|
Before Width: | Height: | Size: 74 KiB After Width: | Height: | Size: 73 KiB |
|
Before Width: | Height: | Size: 50 KiB After Width: | Height: | Size: 50 KiB |
28
scrub.js
@@ -677,12 +677,12 @@ var coolheadersSetup = function (e) {
|
||||
tabId: e.tabId,
|
||||
popup: "torrent.html",
|
||||
});
|
||||
if (tab.url.startsWith("https")){
|
||||
if (tab.url.startsWith("https")) {
|
||||
browser.pageAction.setIcon({
|
||||
path: "icons/infotoopiesbt.png",
|
||||
tabId: e.tabId,
|
||||
});
|
||||
}else{
|
||||
} else {
|
||||
browser.pageAction.setIcon({
|
||||
path: "icons/infotoopiebpt.png",
|
||||
tabId: e.tabId,
|
||||
@@ -705,18 +705,18 @@ var coolheadersSetup = function (e) {
|
||||
|
||||
function getTabURL(tab) {
|
||||
if (tab.url.startsWith("https")) {
|
||||
console.log(tab.url)
|
||||
if (tab.url.endsWith(".i2p/")){
|
||||
browser.pageAction.setPopup({
|
||||
tabId: tab.id,
|
||||
popup: "security.html",
|
||||
});
|
||||
browser.pageAction.setIcon({
|
||||
path: "icons/infotoopies.png",
|
||||
tabId: tab.id,
|
||||
});
|
||||
//console.log("(background) tabinfo", tabInfo[0].id)
|
||||
}
|
||||
console.log(tab.url);
|
||||
if (tab.url.endsWith(".i2p/")) {
|
||||
browser.pageAction.setPopup({
|
||||
tabId: tab.id,
|
||||
popup: "security.html",
|
||||
});
|
||||
browser.pageAction.setIcon({
|
||||
path: "icons/infotoopies.png",
|
||||
tabId: tab.id,
|
||||
});
|
||||
//console.log("(background) tabinfo", tabInfo[0].id)
|
||||
}
|
||||
try {
|
||||
browser.tabs
|
||||
.sendMessage(tab.id, { req: "i2p-location" })
|
||||
|
||||