Merge pull request #15512 from Snuffleupagus/issue-15509
[JS] Override the `Doc.external`-getter to avoid `alert`-modals on load (issue 15509)
This commit is contained in:
commit
5675a6ee64
@ -18,6 +18,8 @@ import { PDFObject } from "./pdf_object.js";
|
|||||||
import { PrintParams } from "./print_params.js";
|
import { PrintParams } from "./print_params.js";
|
||||||
import { ZoomType } from "./constants.js";
|
import { ZoomType } from "./constants.js";
|
||||||
|
|
||||||
|
const DOC_EXTERNAL = false;
|
||||||
|
|
||||||
class InfoProxyHandler {
|
class InfoProxyHandler {
|
||||||
static get(obj, prop) {
|
static get(obj, prop) {
|
||||||
return obj[prop.toLowerCase()];
|
return obj[prop.toLowerCase()];
|
||||||
@ -272,7 +274,10 @@ class Doc extends PDFObject {
|
|||||||
}
|
}
|
||||||
|
|
||||||
get external() {
|
get external() {
|
||||||
return true;
|
// According to the specification this should be `true` in non-Acrobat
|
||||||
|
// applications, however we ignore that to avoid bothering users with
|
||||||
|
// an `alert`-dialog on document load (see issue 15509).
|
||||||
|
return DOC_EXTERNAL;
|
||||||
}
|
}
|
||||||
|
|
||||||
set external(_) {
|
set external(_) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user