<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array"/>
  <modified type="array">
    <modified>
      <diff>@@ -321,8 +321,19 @@ var greasemonkeyService = {
     if (!GM_apiLeakCheck(&quot;GM_openInTab&quot;)) {
       return undefined;
     }
-    var newTab = chromeWin.openNewTabWith(
-      url, safeContentWin.document, null, null, null, null);
+
+    var info = Cc[&quot;@mozilla.org/xre/app-info;1&quot;]
+      .getService(Components.interfaces.nsIXULAppInfo);
+    if (parseFloat(info.version, 10) &lt; 3.0) {
+      // Pre FF 3.0 wants the URL as the second argument.
+      var newTab = chromeWin.openNewTabWith(
+        url, safeContentWin.document.location.href, null, null, null, null);
+    } else {
+      // Post FF 3.0 wants the document as the second argument.
+      var newTab = chromeWin.openNewTabWith(
+        url, safeContentWin.document, null, null, null, null);
+    }
+
     // Source:
     // http://mxr.mozilla.org/mozilla-central/source/browser/base/content/browser.js#4448
     var newWindow = chromeWin.gBrowser</diff>
      <filename>components/greasemonkey.js</filename>
    </modified>
  </modified>
  <removed type="array"/>
  <parents type="array">
    <parent>
      <id>37ff12ad1c9f95492b73d6152f604ecb2dae45fc</id>
    </parent>
  </parents>
  <author>
    <name>Anthony Lieuallen</name>
    <email>arantius@gmail.com</email>
  </author>
  <url>http://github.com/teramako/greasemonkey-for-prism/commit/8cd73827a13f4296fada705ee2f8330e43de64ec</url>
  <id>8cd73827a13f4296fada705ee2f8330e43de64ec</id>
  <committed-date>2009-09-20T08:20:05-07:00</committed-date>
  <authored-date>2009-09-20T08:20:05-07:00</authored-date>
  <message>Pass the proper arguments for various FF versions.

Detect which version of firefox we are running in, and pass the proper
arguments to openNewTabWith(), as it changed across version 2 and 3.

Fixes #1003</message>
  <tree>d43abf0408295ef439327b353b69c8ac559e8f20</tree>
  <committer>
    <name>Anthony Lieuallen</name>
    <email>arantius@gmail.com</email>
  </committer>
</commit>
