Stop including isOffscreenCanvasSupported
in the "StartRenderPage" message
With the previous commit this is now completely unused in API, hence it can be removed. This is done in a separate commit to make it easier to re-instate it, would the need ever arise.
This commit is contained in:
parent
fc055dbd80
commit
50c844c5b8
@ -417,8 +417,6 @@ class Page {
|
||||
this.resources,
|
||||
this.nonBlendModesSet
|
||||
),
|
||||
isOffscreenCanvasSupported:
|
||||
this.evaluatorOptions.isOffscreenCanvasSupported,
|
||||
pageIndex: this.pageIndex,
|
||||
cacheKey,
|
||||
});
|
||||
|
@ -1521,25 +1521,19 @@ class PDFPageProxy {
|
||||
intentState.displayReadyCapability.promise,
|
||||
optionalContentConfigPromise,
|
||||
])
|
||||
.then(
|
||||
([
|
||||
{ transparency, isOffscreenCanvasSupported },
|
||||
optionalContentConfig,
|
||||
]) => {
|
||||
if (this.#pendingCleanup) {
|
||||
complete();
|
||||
return;
|
||||
}
|
||||
this._stats?.time("Rendering");
|
||||
|
||||
internalRenderTask.initializeGraphics({
|
||||
transparency,
|
||||
isOffscreenCanvasSupported,
|
||||
optionalContentConfig,
|
||||
});
|
||||
internalRenderTask.operatorListChanged();
|
||||
.then(([transparency, optionalContentConfig]) => {
|
||||
if (this.#pendingCleanup) {
|
||||
complete();
|
||||
return;
|
||||
}
|
||||
)
|
||||
this._stats?.time("Rendering");
|
||||
|
||||
internalRenderTask.initializeGraphics({
|
||||
transparency,
|
||||
optionalContentConfig,
|
||||
});
|
||||
internalRenderTask.operatorListChanged();
|
||||
})
|
||||
.catch(complete);
|
||||
|
||||
return renderTask;
|
||||
@ -1763,7 +1757,7 @@ class PDFPageProxy {
|
||||
/**
|
||||
* @private
|
||||
*/
|
||||
_startRenderPage(transparency, isOffscreenCanvasSupported, cacheKey) {
|
||||
_startRenderPage(transparency, cacheKey) {
|
||||
const intentState = this._intentStates.get(cacheKey);
|
||||
if (!intentState) {
|
||||
return; // Rendering was cancelled.
|
||||
@ -1772,10 +1766,7 @@ class PDFPageProxy {
|
||||
|
||||
// TODO Refactor RenderPageRequest to separate rendering
|
||||
// and operator list logic
|
||||
intentState.displayReadyCapability?.resolve({
|
||||
transparency,
|
||||
isOffscreenCanvasSupported,
|
||||
});
|
||||
intentState.displayReadyCapability?.resolve(transparency);
|
||||
}
|
||||
|
||||
/**
|
||||
@ -2737,11 +2728,7 @@ class WorkerTransport {
|
||||
}
|
||||
|
||||
const page = this.#pageCache.get(data.pageIndex);
|
||||
page._startRenderPage(
|
||||
data.transparency,
|
||||
data.isOffscreenCanvasSupported,
|
||||
data.cacheKey
|
||||
);
|
||||
page._startRenderPage(data.transparency, data.cacheKey);
|
||||
});
|
||||
|
||||
messageHandler.on("commonobj", ([id, type, exportedData]) => {
|
||||
@ -3303,11 +3290,7 @@ class InternalRenderTask {
|
||||
});
|
||||
}
|
||||
|
||||
initializeGraphics({
|
||||
transparency = false,
|
||||
isOffscreenCanvasSupported = false,
|
||||
optionalContentConfig,
|
||||
}) {
|
||||
initializeGraphics({ transparency = false, optionalContentConfig }) {
|
||||
if (this.cancelled) {
|
||||
return;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user