>Форум Mozilla Россия http://forum.mozilla-russia.org/index.php >Firefox http://forum.mozilla-russia.org/viewforum.php?id=4 >Работа с закладками http://forum.mozilla-russia.org/viewtopic.php?id=74506 |
Stkvsky > 23-04-2019 13:41:00 |
Вот есть три одинаковых закладки (найдены поиском), все они в разных папках, как узнать в какой папке какая закладка? скрытый текст |
oleg.sgh > 23-04-2019 16:00:44 |
Acid Crash > 23-04-2019 16:37:46 |
Приветствую. скрытый текст |
Stkvsky > 23-04-2019 17:03:29 |
oleg.sgh Acid Crash |
Stkvsky > 23-04-2019 18:09:21 |
Еще интересует как можно выделить цветом вкладку добавленую в закладки. скрытый текст Выделить код Код:// Выделение вкладки добавленой в закладки .......... ({ style: ` @namespace url(http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul); .tabbrowser-tab[inbookmarks] .tab-text.tab-label { font-weight: bold !important; } `.trim(), addProcessingInstruction: function(add) { if (add) { this.pi = document.createProcessingInstruction("xml-stylesheet", `type="text/css" href="data:text/css,${encodeURIComponent(this.style)}"` ); document.insertBefore(this.pi, document.firstChild); } else this.pi.remove(); }, init: function() { this.addProcessingInstruction(true); this.setAttributeForAllTabs(true); gBrowser.addTabsProgressListener(this); PlacesUtils.addLazyBookmarkObserver(this); addDestructor(this.destroy, this); }, destroy: function() { this.addProcessingInstruction(false); this.setAttributeForAllTabs(false); gBrowser.removeTabsProgressListener(this); PlacesUtils.removeLazyBookmarkObserver(this); }, isBookmarked: uri => Boolean(PlacesUtils.getBookmarksForURI(uri).length), onIlebedevdded: function(id, parent, ind, type, uri) this.onItem(type, uri), onItemRemoved: function(id, parent, ind, type, uri) this.onItem(type, uri), onItemChanged: function(id, property, isAnno, value, lm, type) property == "uri" && this.onItem(type), onItem: function(type, uri) { type == Ci.nsINavBookmarksService.TYPE_BOOKMARK && this.setAttributeForAllTabs(true, uri); }, onLocationChange: function(browser, wp, req, uri) { var tab = gBrowser.getTabForBrowser(browser); this.setAttributeForTab(tab, this.isBookmarked(uri)); }, setAttributeForAllTabs: function(set, uri) { for(var tab of gBrowser.tabs) { var curr = tab.linkedBrowser.currentURI; if (uri && !uri.equals(curr)) continue; var state = set && this.isBookmarked(curr); this.setAttributeForTab(tab, state); } }, setAttributeForTab: function(tab, set) { set ? tab.setAttribute("inbookmarks", true) : tab.removeAttribute("inbookmarks"); } }).init(); |
Sergeys > 24-04-2019 16:18:14 |
тема в faq - ищу расширение (ищу дополнение) |