Fx60: Fix text links in About pane and preferences
This commit is contained in:
parent
6b7b57da3c
commit
c67e29adc7
1 changed files with 5 additions and 11 deletions
|
@ -53,7 +53,7 @@
|
||||||
<body>
|
<body>
|
||||||
<![CDATA[
|
<![CDATA[
|
||||||
var href = this.href;
|
var href = this.href;
|
||||||
if (!href || this.disabled || aEvent.getPreventDefault())
|
if (!href || this.disabled || aEvent.defaultPrevented)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
var uri = null;
|
var uri = null;
|
||||||
|
@ -83,16 +83,10 @@
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
const cID = "@mozilla.org/uriloader/external-protocol-service;1";
|
// Open HTTP URLs externally
|
||||||
const nsIEPS = Components.interfaces.nsIExternalProtocolService;
|
if (window.Zotero && ["http", "https"].includes(uri.scheme)) {
|
||||||
var protocolSvc = Components.classes[cID].getService(nsIEPS);
|
Zotero.launchURL(uri.spec);
|
||||||
|
aEvent.preventDefault();
|
||||||
// if the scheme is not an exposed protocol, then opening this link
|
|
||||||
// should be deferred to the system's external protocol handler
|
|
||||||
if (!protocolSvc.isExposedProtocol(uri.scheme)
|
|
||||||
|| (window.Zotero && window.Zotero.isStandalone && ["http", "https"].indexOf(uri.scheme) !== -1)) {
|
|
||||||
protocolSvc.loadUrl(uri);
|
|
||||||
aEvent.preventDefault()
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue