Multiple context menu entries for a chrome extension?
I've been playing around with a Chrome extension to enable me to right click on some selection of text and search that text on a site like Wikipedia or IMDb. I've managed to do this, but when I right click I would prefer to have the options listed one after the other. The way Chrome context menu extensions work by default cause any items to be gathered under one parent menu, as described here: http://code.google.com/chrome/extensions/contextMenus.html
It d开发者_JAVA百科oes not specifically mention, however, that items absolutely cannot be listed individually. I haven't seen anything to suggest how it could be done though. I imagine creating separate extensions would work, but that's not an ideal solution.
Anybody have any ideas?
There's no workaround than creating multiple extensions. It's clearly stated in the Google Chrome Developer page that it doesn't allow more than one item on the main context menu. If an extension tries to create more than one item, Chrome will collapse all of them into one single parent item.
精彩评论