mirror of
https://github.com/zen-browser/pdf.js.git
synced 2025-07-09 09:45:42 +02:00
[api-minor] Allow specifying an extra-delay, in RenderTask.cancel
, for worker-thread aborting of operatorList parsing
This is done to support upcoming viewer-changes, and in order to prevent third-party users from outright breaking things we'll simply ignore too large values.
This commit is contained in:
parent
e182597cb1
commit
91524d1a60
3 changed files with 20 additions and 6 deletions
|
@ -332,9 +332,10 @@ class PageViewport {
|
|||
}
|
||||
|
||||
class RenderingCancelledException extends BaseException {
|
||||
constructor(msg, type) {
|
||||
constructor(msg, type, extraDelay = 0) {
|
||||
super(msg, "RenderingCancelledException");
|
||||
this.type = type;
|
||||
this.extraDelay = extraDelay;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue