I got a question to ask on building firefox plugin, basically my aim is to do following things,
1) In my plugin I want to show right click context menu item for only links[anchor tags] and hide the menu item for rest of the page
2) How to add dynamic list to my menu, i.e., adding the number of menu list items dynamically depending upon user’s choice.
Can someOne point me to a right direction
Thanks !!
Bind an event listener for the
contextmenuevent and check whether the clicked element is a link, e.g.:Read more about event properties and the
menuelement properties.Have a look at the
menuelement‘sappendItemmethod.