// Вернуть иконки сайтов в адресной строке ............... addEventListener("TabAttrModified", (e, tab = e.target)=> { if ( tab.selected ) favIcon.src = tab.image || "chrome://global/skin/icons/Portrait.png"; }, true, gBrowser.tabContainer); var favIcon = document.getElementById("page-proxy-favicon") || document.getElementById("identity-icon"); addDestructor(()=> favIcon.removeAttribute("src") ); // ПКМ по иконке в копирует адрес............. addEventListener("click", function(e) { e.preventDefault(); e.stopPropagation(); // ПКМ копирует текущий адрес .... if ( e.button == 2) { gClipboard.write( content.location ); // значок идентификации сайта мигает красным .... document.getElementById("identity-box").style.background = "red"; setTimeout(function() { document.getElementById("identity-box").style.background = "" }, 500); } }, true, document.getElementById("identity-box") ); |