Answer the question
In order to leave comments, you need to log in
Getting to the "Show More Bookmarks" Button in Firefox
I am developing an extension for Firefox that allows you to display the bookmarks bar by hotkey, and hide it when you click on the bookmark.
It seems like everything works great and the plugin is almost ready, but a bug was found out: if the number of bookmarks exceeds the number that fit on the screen, then the “Show more bookmarks” button appears, after clicking which a list of bookmarks that do not fit on the screen appears. So, when you click on a bookmark located inside this button/menu, the bookmark panel does not want to be automatically hidden.
Here, on the right, is this ill-fated button:
Tell me, how can I get to this button from javascript? And in particular, and to the elements (bookmarks) drop-down by clicking on it.
If you look through the DOM Inspector, then there seems to be this button, but you can’t get to it.
Copy Source | Copy HTML
- var tmp_str = '';
- for (i=0; i<content.childNodes.length; i++){
- // Вешаю обработчик клика мышкой
- content.childNodes[i].addEventListener("click", this.onMouseClick, false);
- // Пытаюсь понять до какого элемента добрался (для отдалки)
- tmp_str = tmp_str+ i+'node='+content.childNodes[i].nodeName+'; tag='+content.childNodes[i].tagName+'; class='+content.childNodes[i].className+'; local='+content.childNodes[i].localName+'; Type='+content.childNodes[i].nodeType+'; Value='+content.childNodes[i].nodeValue+'\n';
- }
- // Показываю весь список элементов на которые повешено событие клика мышкой (для отладки)
- alert(tmp_str);
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question