Advertisement
Guest User

Untitled

a guest
Oct 23rd, 2014
139
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.61 KB | None | 0 0
  1. Uncaught TypeError: undefined is not a function
  2.  
  3. chrome.contextMenus.create({
  4. id:"click-me",
  5. title: "click-me",
  6. contexts : ["all"]
  7. });
  8.  
  9. chrome.contextMenus.onClicked.AddListener(function(info, tab){
  10. alert("A context menu entry has been clicked: " + info.menuItemId);
  11. });
  12.  
  13. {
  14. "manifest_version" : 2,
  15. "name": "Sample",
  16. "version": "1.0",
  17. "icons" : {
  18. "128" : "128.png"
  19. },
  20. "background" : {
  21. "scripts" : ["background.js"],
  22. "persistent" : false
  23. },
  24. "permissions":[
  25. "contextMenus",
  26. "tabs"
  27. ],
  28. "browser_action" : {
  29. "default_icon" : {
  30. "128" : "128.png"
  31. }
  32. }
  33. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement