mirror of
https://github.com/mozilla/pdf.js.git
synced 2025-04-22 16:18:08 +02:00
Use OffscreenCanvas
as intended for all code-paths in src/display/text_layer.js
(PR 15722 follow-up)
Currently some `getCtx` calls will have `isOffscreenCanvasSupported === undefined` set, meaning that `OffscreenCanvas` isn't being used as intended, since no `TextLayerRenderTask._isOffscreenCanvasSupported` property exists. *Please note:* This patch is written using the GitHub UI, since I'm currently without a dev machine, so hopefully it works correctly.
This commit is contained in:
parent
9c58d4f7f2
commit
5075d0495b
1 changed files with 1 additions and 0 deletions
|
@ -311,6 +311,7 @@ class TextLayerRenderTask {
|
|||
this._container = this._rootContainer = container;
|
||||
this._textDivs = textDivs || [];
|
||||
this._textContentItemsStr = textContentItemsStr || [];
|
||||
this._isOffscreenCanvasSupported = isOffscreenCanvasSupported;
|
||||
this._fontInspectorEnabled = !!globalThis.FontInspector?.enabled;
|
||||
|
||||
this._reader = null;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue