Bug 630542 - Regression: Context menus do not pop up on links [r=stechz]
authorMark Finkle <mfinkle@mozilla.com>
Tue, 01 Feb 2011 13:59:58 -0500
changeset 2728 6987c7f6e2528c56750f4e7f6f570f83bff8909f
parent 2727 994fa1d84081894f92dcee9f1a8e75c1f9af5de4
child 2729 c2d8239a31ca840a2243ca909d1c8660fa6d5903
push id2291
push usermfinkle@mozilla.com
push dateTue, 01 Feb 2011 18:59:53 +0000
reviewersstechz
bugs630542
Bug 630542 - Regression: Context menus do not pop up on links [r=stechz]
chrome/content/content.js
--- a/chrome/content/content.js
+++ b/chrome/content/content.js
@@ -249,17 +249,19 @@ let Content = {
 
     addEventListener("MozApplicationManifest", this, false);
     addEventListener("command", this, false);
     addEventListener("pagehide", this, false);
     addEventListener("keypress", this, false, false);
 
     this._formAssistant = new FormAssistant();
 
-    docShell.QueryInterface(Ci.nsIDocShellHistory).useGlobalHistory = true;
+    try{
+      docShell.QueryInterface(Ci.nsIDocShellHistory).useGlobalHistory = true;
+    } catch(e) { dump("---error: " + e + "\n"); }
   },
 
   handleEvent: function handleEvent(aEvent) {
     switch (aEvent.type) {
       // If the keypress is a trusted event and has not been consume by content
       // let's send it back to the chrome process to have it handle shortcuts
       case "keypress":
         let timer = new Util.Timeout(function() {