The webconsole from FF outputs a hyperlink to the js debugger/source when an error/warning occurs. Is it possible to create such a link in my own devtools extension. And when yes, how?
Yep, what's the chrome url of that page?
Set it in here:
var sa = Cc["@mozilla.org/supports-array;1"].createInstance(Ci.nsISupportsArray);
var wuri = Cc["@mozilla.org/supports-string;1"].createInstance(Ci.nsISupportsString);
wuri.data = 'about:blank';
sa.AppendElement(wuri);
let features = "chrome,dialog=no";
var XULWindow = Services.ww.openWindow(null, 'chrome://global/content/viewSource.xul', null, features, sa);
XULWindow.addEventListener('load', function() {
}, false);
Set wuri.data = 'about:blank';
to the url of whatever sites source you want to load.