mirror of
https://github.com/zen-browser/pdf.js.git
synced 2025-07-10 10:15:37 +02:00
Stop special-casing the dict
parameter in the Jbig2Stream
/JpegStream
/JpxStream
constructors
For all of the other `DecodeStream`s we're not passing in a `Dict`-instance manually, but instead get it from the `stream`-parameter. Hence there's no particularly good reason, as far as I can tell, to not do the same thing in `Jbig2Stream`/`JpegStream`/`JpxStream` as well.
This commit is contained in:
parent
67a1cfc1b1
commit
fb0775525e
4 changed files with 9 additions and 9 deletions
|
@ -23,7 +23,7 @@ import { shadow } from "../shared/util.js";
|
|||
* like all the other DecodeStreams.
|
||||
*/
|
||||
class JpegStream extends DecodeStream {
|
||||
constructor(stream, maybeLength, dict, params) {
|
||||
constructor(stream, maybeLength, params) {
|
||||
// Some images may contain 'junk' before the SOI (start-of-image) marker.
|
||||
// Note: this seems to mainly affect inline images.
|
||||
let ch;
|
||||
|
@ -37,8 +37,8 @@ class JpegStream extends DecodeStream {
|
|||
super(maybeLength);
|
||||
|
||||
this.stream = stream;
|
||||
this.dict = stream.dict;
|
||||
this.maybeLength = maybeLength;
|
||||
this.dict = dict;
|
||||
this.params = params;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue