Limit even more SVG-specific code to the GENERIC viewer

Given that the SVG back-end is not defined anywhere except in GENERIC builds, we can remove a bit more unnecessary code in e.g. the Firefox PDF Viewer.
This commit is contained in:
Jonas Jenwald 2022-07-19 13:41:01 +02:00
parent bf7eef7109
commit f4e60ae986
3 changed files with 24 additions and 9 deletions

View file

@ -48,10 +48,13 @@ const SidebarView = {
LAYERS: 4,
};
const RendererType = {
CANVAS: "canvas",
SVG: "svg",
};
const RendererType =
typeof PDFJSDev === "undefined" || PDFJSDev.test("!PRODUCTION || GENERIC")
? {
CANVAS: "canvas",
SVG: "svg",
}
: null;
const TextLayerMode = {
DISABLE: 0,