Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

Issue 5738 (Firebug help links should be https:)

  • Loading branch information...
commit 8bc0ed74f24eca3e5ee8d06c721ba81ce91de59e 1 parent bbc65b9
Sebastian Zartner SebastianZ authored janodvarko committed
31 extension/content/firebug/chrome/chrome.js
@@ -17,7 +17,7 @@ define([
17 17 "firebug/lib/events",
18 18 "firebug/js/fbs",
19 19 "firebug/chrome/window",
20   - "firebug/lib/options",
  20 + "firebug/lib/options"
21 21 ],
22 22 function chromeFactory(Obj, Firefox, Dom, Css, System, Menu, Toolbar, Url, Locale, String,
23 23 Events, FBS, Win, Options) {
@@ -39,6 +39,21 @@ const LOAD_FLAGS_NONE = nsIWebNavigation.LOAD_FLAGS_NONE;
39 39
40 40 const panelURL = "chrome://firebug/content/panel.html";
41 41
  42 +// URLs used in the Firebug Menu and several other places
  43 +const firebugURLs =
  44 +{
  45 + main: "https://getfirebug.com",
  46 + help: "https://getfirebug.com/help",
  47 + FAQ: "https://getfirebug.com/wiki/index.php/FAQ",
  48 + docs: "https://getfirebug.com/docs.html",
  49 + keyboard: "https://getfirebug.com/wiki/index.php/Keyboard_and_Mouse_Shortcuts",
  50 + discuss: "https://groups.google.com/forum/#!forum/firebug",
  51 + issues: "http://code.google.com/p/fbug/issues/list?can=1",
  52 + donate: "https://getfirebug.com/getinvolved",
  53 + extensions: "https://getfirebug.com/wiki/index.php/Firebug_Extensions",
  54 + issue5110: "http://code.google.com/p/fbug/issues/detail?id=5110"
  55 +};
  56 +
42 57 const statusCropSize = 20;
43 58
44 59 // ********************************************************************************************* //
@@ -1715,6 +1730,20 @@ var FirebugChrome =
1715 1730 },
1716 1731
1717 1732 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
  1733 +
  1734 + visitWebsite: function(which, arg)
  1735 + {
  1736 + var url = firebugURLs[which];
  1737 + if (url)
  1738 + {
  1739 + if (arg)
  1740 + url += arg;
  1741 +
  1742 + Win.openNewTab(url);
  1743 + }
  1744 + },
  1745 +
  1746 + // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
1718 1747 // Main Toolbar
1719 1748
1720 1749 appendToolbarButton: function(button, before)
18 extension/content/firebug/firebug.js
@@ -43,19 +43,6 @@ const versionURL = "chrome://firebug/content/branch.properties";
43 43
44 44 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
45 45
46   -const firebugURLs = // TODO chrome.js
47   -{
48   - main: "http://www.getfirebug.com",
49   - help: "http://www.getfirebug.com/help",
50   - FAQ: "http://getfirebug.com/wiki/index.php/FAQ",
51   - docs: "http://www.getfirebug.com/docs.html",
52   - keyboard: "http://getfirebug.com/wiki/index.php/Keyboard_and_Mouse_Shortcuts",
53   - discuss: "http://groups.google.com/group/firebug",
54   - issues: "http://code.google.com/p/fbug/issues/list",
55   - donate: "http://getfirebug.com/getinvolved",
56   - issue5110: "http://code.google.com/p/fbug/issues/detail?id=5110"
57   -};
58   -
59 46 const scriptBlockSize = 20;
60 47
61 48 const PLACEMENT_NONE = 0;
@@ -1298,11 +1285,6 @@ window.Firebug =
1298 1285
1299 1286 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
1300 1287
1301   - visitWebsite: function(which)
1302   - {
1303   - Win.openNewTab(firebugURLs[which]);
1304   - },
1305   -
1306 1288 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
1307 1289 // nsISupports
1308 1290
48 extension/content/firebug/firefox/browserOverlay.js
@@ -11,21 +11,9 @@ Cu.import("resource://firebug/fbtrace.js");
11 11 Cu.import("resource://firebug/loader.js");
12 12 Cu.import("resource://firebug/prefLoader.js");
13 13
14   -var Locale = Cu.import("resource://firebug/locale.js").Locale;
  14 +const firstRunPage = "https://getfirebug.com/firstrun#Firebug ";
15 15
16   -// Firebug URLs used by the global menu.
17   -var firebugURLs =
18   -{
19   - main: "http://www.getfirebug.com",
20   - FAQ: "http://getfirebug.com/wiki/index.php/FAQ",
21   - docs: "http://www.getfirebug.com/docs.html",
22   - keyboard: "http://getfirebug.com/wiki/index.php/Keyboard_and_Mouse_Shortcuts",
23   - discuss: "https://groups.google.com/forum/#!forum/firebug",
24   - issues: "http://code.google.com/p/fbug/issues/list",
25   - donate: "http://getfirebug.com/getinvolved",
26   - extensions: "http://getfirebug.com/wiki/index.php/Firebug_Extensions",
27   - firstRunPage: "http://getfirebug.com/firstrun#Firebug "
28   -};
  16 +var Locale = Cu.import("resource://firebug/locale.js").Locale;
29 17
30 18 // ********************************************************************************************* //
31 19 // String Bundles
@@ -321,7 +309,7 @@ Firebug.GlobalUI =
321 309
322 310 var container = $("appcontent");
323 311
324   - // List of Firbug scripts that must be loaded into the global scope (browser.xul)
  312 + // List of Firebug scripts that must be loaded into the global scope (browser.xul)
325 313 var scriptSources = [
326 314 "chrome://firebug/content/trace.js",
327 315 "chrome://firebug/content/legacy.js",
@@ -517,14 +505,11 @@ Firebug.GlobalUI =
517 505 });
518 506 },
519 507
520   - visitWebsite: function(which, arg)
  508 + openFirstRunPage: function()
521 509 {
522   - var url = firebugURLs[which];
523   - if (url)
524   - {
525   - url = arg ? url + arg : url;
526   - gBrowser.selectedTab = gBrowser.addTab(url, null, null, null);
527   - }
  510 + var version = Firebug.GlobalUI.getVersion();
  511 + url = firstRunPage + version;
  512 + gBrowser.selectedTab = gBrowser.addTab(url, null, null, null);
528 513 },
529 514
530 515 setPosition: function(newPosition)
@@ -948,7 +933,7 @@ var firebugMenuContent = [
948 933 id: "menu_firebug_firebugUrlWebsite",
949 934 label: "firebug.Website",
950 935 tooltiptext: "firebug.menu.tip.Website",
951   - oncommand: "Firebug.GlobalUI.visitWebsite('main')",
  936 + oncommand: "Firebug.chrome.visitWebsite('main')",
952 937 "class": "fbInternational"
953 938 }),
954 939 $menuitem(
@@ -956,7 +941,7 @@ var firebugMenuContent = [
956 941 id: "menu_firebug_firebugUrlExtensions",
957 942 label: "firebug.menu.Extensions",
958 943 tooltiptext: "firebug.menu.tip.Extensions",
959   - oncommand: "Firebug.GlobalUI.visitWebsite('extensions')",
  944 + oncommand: "Firebug.chrome.visitWebsite('extensions')",
960 945 "class": "fbInternational"
961 946 }),
962 947 $menuitem(
@@ -973,7 +958,7 @@ var firebugMenuContent = [
973 958 id: "menu_firebug_firebugDoc",
974 959 label: "firebug.Documentation",
975 960 tooltiptext: "firebug.menu.tip.Documentation",
976   - oncommand: "Firebug.GlobalUI.visitWebsite('docs')",
  961 + oncommand: "Firebug.chrome.visitWebsite('docs')",
977 962 "class": "fbInternational"
978 963 }),
979 964 $menuitem(
@@ -981,7 +966,7 @@ var firebugMenuContent = [
981 966 id: "menu_firebug_firebugKeyboard",
982 967 label: "firebug.KeyShortcuts",
983 968 tooltiptext: "firebug.menu.tip.Key_Shortcuts",
984   - oncommand: "Firebug.GlobalUI.visitWebsite('keyboard')",
  969 + oncommand: "Firebug.chrome.visitWebsite('keyboard')",
985 970 "class": "fbInternational"
986 971 }),
987 972 $menuitem(
@@ -989,7 +974,7 @@ var firebugMenuContent = [
989 974 id: "menu_firebug_firebugForums",
990 975 label: "firebug.Forums",
991 976 tooltiptext: "firebug.menu.tip.Forums",
992   - oncommand: "Firebug.GlobalUI.visitWebsite('discuss')",
  977 + oncommand: "Firebug.chrome.visitWebsite('discuss')",
993 978 "class": "fbInternational"
994 979 }),
995 980 $menuitem(
@@ -997,7 +982,7 @@ var firebugMenuContent = [
997 982 id: "menu_firebug_firebugIssues",
998 983 label: "firebug.Issues",
999 984 tooltiptext: "firebug.menu.tip.Issues",
1000   - oncommand: "Firebug.GlobalUI.visitWebsite('issues')",
  985 + oncommand: "Firebug.chrome.visitWebsite('issues')",
1001 986 "class": "fbInternational"
1002 987 }),
1003 988 $menuitem(
@@ -1005,7 +990,7 @@ var firebugMenuContent = [
1005 990 id: "menu_firebug_firebugDonate",
1006 991 label: "firebug.Donate",
1007 992 tooltiptext: "firebug.menu.tip.Donate",
1008   - oncommand: "Firebug.GlobalUI.visitWebsite('donate')",
  993 + oncommand: "Firebug.chrome.visitWebsite('donate')",
1009 994 "class": "fbInternational"
1010 995 }),
1011 996 ])
@@ -1209,9 +1194,7 @@ if ((!$("firebug-button") || $("firebug-button").parentNode.tagName == "toolbarp
1209 1194 // Check whether insertItem really works
1210 1195 var curSet = navBar.currentSet.split(",");
1211 1196 if (curSet.indexOf(startButtonId) == -1)
1212   - {
1213 1197 FBTrace.sysout("Startbutton; navBar.insertItem doesn't work", curSet);
1214   - }
1215 1198
1216 1199 if (FBTrace.DBG_INITIALIZE)
1217 1200 FBTrace.sysout("Startbutton; curSet (after modification): " + navBar.currentSet);
@@ -1274,8 +1257,7 @@ if (checkFirebugVersion(PrefLoader.getPref("currentVersion")) > 0)
1274 1257 if (window.closed)
1275 1258 return;
1276 1259
1277   - var version = Firebug.GlobalUI.getVersion();
1278   - Firebug.GlobalUI.visitWebsite("firstRunPage", version);
  1260 + Firebug.GlobalUI.openFirstRunPage();
1279 1261 }, 1000);
1280 1262
1281 1263 window.addEventListener("unload", function()
2  extension/content/firebug/firefox/firebugMenuOverlay.xul
@@ -71,7 +71,7 @@
71 71 <command id="cmd_firebug_toggleCommandPopup" oncommand="Firebug.CommandLine.Popup.toggle(Firebug.currentContext)"
72 72 checked="false"/>
73 73
74   - <command id="cmd_firebug_openHelp" oncommand="Firebug.visitWebsite('help');"/>
  74 + <command id="cmd_firebug_openHelp" oncommand="Firebug.chrome.visitWebsite('help');"/>
75 75 <command id="cmd_firebug_openInEditor" oncommand="Firebug.ExternalEditors.onContextMenuCommand(event);"/>
76 76 </commandset>
77 77
2  extension/content/firebug/js/scriptPanel.js
@@ -1946,7 +1946,7 @@ Firebug.ScriptPanel.WarningRep = domplate(Firebug.Rep,
1946 1946 var box = this.tag.replace(args, parentNode, this);
1947 1947 var description = box.getElementsByClassName("disabledPanelDescription").item(0);
1948 1948 FirebugReps.Description.render(args.suggestion, description,
1949   - Obj.bindFixed(Firebug.visitWebsite, this, "issue5110"));
  1949 + Obj.bindFixed(Firebug.chrome.visitWebsite, this, "issue5110"));
1950 1950
1951 1951 return box;
1952 1952 },

0 comments on commit 8bc0ed7

Please sign in to comment.
Something went wrong with that request. Please try again.