Remove a (now) unnecessary externalLinkTarget check in PDFViewerApplication._readPreferences

The only reason that this check ever existed in the first place, is that originally there was a global `PDFJS.openExternalLinkInNewWindow` option which was then subsumed by the (more generic) `PDFJS.externalLinkTarget` option. (The `externalLinkTarget` has since been moved into a `PDFLinkService` option, as part of PDF.js version `2.0`.)

Hence, during the period where both `PDFJS.openExternalLinkInNewWindow` and `PDFJS.externalLinkTarget` existed side-by-side, there was a need to allow the former one to override the latter one (for backward compatibility purposes). However, that's no longer the case, and this extra `externalLinkTarget` check can now be removed.
This commit is contained in:
Jonas Jenwald 2018-07-23 20:12:24 +02:00
parent c6a0ae08f1
commit c3433aea48

View File

@ -223,9 +223,6 @@ let PDFViewerApplication = {
AppOptions.set('useOnlyCssZoom', value);
}),
preferences.get('externalLinkTarget').then(function resolved(value) {
if (AppOptions.get('externalLinkTarget') !== LinkTarget.NONE) {
return;
}
AppOptions.set('externalLinkTarget', value);
}),
preferences.get('renderer').then(function resolved(value) {