Remove bookmark with right click in location bar suggestions

Hi,
I have location bar set to bookmarks in about:preferences#privacy. When I then type into the location bar, only bookmarks are suggested. When I then click the left button on some bookmark it loads page in current tab, when I click middle button it loads page in new foreground tab and when I click right button it does nothing. Would it be possible to make some addon to remove site from bookmarks then? Withnout any confirmation?
And is this the right place to request for addon like this? And if not, where I please could make a request of this kind?
I really appreciate any help you can provide.

This addon also should be able to remove loaded page from bookmarks by clicking bookmark star button (also with right mouse button and without confirmation) and via keyboard shortcut.
I would be a first contributor of this addon of course.

I use extension called Menu Wizard for some time now. See:
https://addons.mozilla.org/en-US/firefox/addon/s3menu-wizard/developers

Its developer states there that he might be able to spend some time creating new addons. So I decided to give it a try and here is the result:
https://forum.mozilla-russia.org/viewtopic.php?id=69556

It is the Custom Buttons code posted by its author itself that does exactly what I requested above:

  1. it removes site from bookmarks by right clicking it in the address/location bar suggestions (when enabled in about:preferences#privacy)
  2. it removes currently active tab from bookmarks by left clicking newly added toolbar button BookmarkRemove
    And everything without any confirmation!

You need to install the Custom Buttons extension to make it work. It can be found here:
https://addons.mozilla.org/en-US/firefox/addon/custom-buttons/

Then you need to copy the code below and paste it in the address bar. Treat this code as a normal URL. Just paste it into address bar and run it. The installation process will start itself then:
custombutton://%3C%3Fxml%20version%3D%221.0%22%20encoding%3D%22UTF-8%22%3F%3E%0D%0A%3Ccustombutton%20xmlns%3Acb%3D%22http%3A//xsms.nm.ru/custombuttons/%22%3E%0A%20%20%3Cname%3EBookmarkRemove%3C/name%3E%0A%20%20%3Cimage%3E%3C%21%5BCDATA%5Bcustombuttons-stdicon-1%5D%5D%3E%3C/image%3E%0A%20%20%3Cmode%3E0%3C/mode%3E%0A%20%20%3Cinitcode%3E%3C%21%5BCDATA%5Bvar%20btn%20%3D%20this%3B%0Avar%20PopupAutoCompleteRichResult%20%3D%20document.getElementById%28%27PopupAutoCompleteRichResult%27%29%3B%0A%0Abtn.addEventListener%28%22click%22%2C%20clickBtn%2C%20true%29%3B%0APopupAutoCompleteRichResult.addEventListener%28%22click%22%2C%20clickPopup%2C%20false%29%3B%0Abtn.onDestroy%20%3D%20function%28%29%20%7B%0A%09btn.removeEventListener%28%22click%22%2C%20clickBtn%2C%20true%29%3B%0A%09PopupAutoCompleteRichResult.removeEventListener%28%22click%22%2C%20clickPopup%2C%20false%29%3B%0A%7D%0A%0Afunction%20clickBtn%28event%29%20%7B%0A%09if%20%28event.button%20%21%3D%200%29%20%7B%20return%3B%20%7D%0A%09event.preventDefault%28%29%3B%0A%09%0A%09var%20url%20%3D%20gBrowser.selectedTab.linkedBrowser.currentURI.spec%3B%0A%09bookmarkRemove%28url%29%3B%0A%7D%0A%0Afunction%20clickPopup%28event%29%20%7B%0A%09if%20%28event.button%20%21%3D%202%29%20%7B%20return%3B%20%7D%0A%09%0A%09var%20item%20%3D%20PopupAutoCompleteRichResult.richlistbox.getSelectedItem%280%29%3B%0A%09if%20%28item%20%26%26%20%28item.getAttribute%28%27type%27%29%20%3D%3D%20%27bookmark%27%29%29%20%7B%0A%09%09var%20url%20%3D%20item.getAttribute%28%27url%27%29%3B%0A%09%09bookmarkRemove%28url%29%3B%0A%09%09item.setAttribute%28%27type%27%2C%20%27favicon%27%29%3B%0A%0A%09%09var%20image%20%3D%20item.ownerDocument.getAnonymousElementByAttribute%28item%2C%20%27anonid%27%2C%20%27type-image%27%29%3B%0A%09%09if%20%28image%29%20%7B%0A%09%09%09image.setAttribute%28%27class%27%2C%20%27ac-type-icon%20ac-result-type-favicon%27%29%3B%0A%09%09%7D%0A%09%09var%20an_url%20%3D%20item.ownerDocument.getAnonymousElementByAttribute%28item%2C%20%27anonid%27%2C%20%27url%27%29%3B%0A%09%09if%20%28an_url%29%20%7B%0A%09%09%09an_url.setAttribute%28%27type%27%2C%20%27favicon%27%29%3B%0A%09%09%7D%0A%09%09var%20an_action%20%3D%20item.ownerDocument.getAnonymousElementByAttribute%28item%2C%20%27anonid%27%2C%20%27action%27%29%3B%0A%09%09if%20%28an_action%29%20%7B%0A%09%09%09an_action.setAttribute%28%27type%27%2C%20%27favicon%27%29%3B%0A%09%09%7D%0A%09%7D%0A%7D%0A%0Afunction%20bookmarkRemove%28url%29%20%7B%0A%09var%20bmsvc%20%3D%20Components.classes%5B%22@mozilla.org/browser/nav-bookmarks-service%3B1%22%5D.getService%28Components.interfaces.nsINavBookmarksService%29%3B%0A%09var%20ios%20%3D%20Components.classes%5B%22@mozilla.org/network/io-service%3B1%22%5D.getService%28Components.interfaces.nsIIOService%29%3B%0A%09var%20uri%20%3D%20ios.newURI%28url%2C%20null%2C%20null%29%3B%0A%09var%20bookmarksArray%20%3D%20bmsvc.getBookmarkIdsForURI%28uri%2C%20%7B%7D%29%3B%0A%09for%20%28var%20i%20of%20bookmarksArray%29%20%7B%0A%09%09bmsvc.removeItem%28i%29%3B%0A%09%7D%0A%7D%0A%5D%5D%3E%3C/initcode%3E%0A%20%20%3Ccode%3E%3C%21%5BCDATA%5B/*CODE*/%5D%5D%3E%3C/code%3E%0A%20%20%3Caccelkey%3E%3C%21%5BCDATA%5B%5D%5D%3E%3C/accelkey%3E%0A%20%20%3Chelp%3E%3C%21%5BCDATA%5B%5D%5D%3E%3C/help%3E%0A%20%20%3Cattributes/%3E%0A%3C/custombutton%3E

Iam so grateful for this extension! Many thanks again. Will donate for sure :wink:

For Add Bookmark Here ² extension users:

To do single-click on STAR to remove bookmark, try:

  1. Right-click on STAR (By default, it should open ABH2 Options Dialog, we will override this behavior later.)
  2. Click [Advanced] tab, Under [Bookmark Star] group, you should see: Left/Middle/Right… settings.
  3. Choose [Show the Dialog with Single Click (Toggle)] from Right-Click row’s drop-down list.
  4. Now, open any bookmarked page, and right-click on the STAR, it should remove the bookmark immediately without any confirmation.

See:
http://forums.mozillazine.org/viewtopic.php?p=14545805#p14545805

Add Bookmark Here ² extension can be found here:
https://addons.mozilla.org/en-US/firefox/addon/add-bookmark-here-2/