mirror of
https://github.com/zen-browser/pdf.js.git
synced 2025-07-08 09:20:06 +02:00
Merge pull request #12446 from Snuffleupagus/firefox-print-RenderingCancelledException
[Firefox] Stop logging `RenderingCancelledException`s as errors when printing
This commit is contained in:
commit
b3e32e2001
1 changed files with 5 additions and 3 deletions
|
@ -13,9 +13,9 @@
|
||||||
* limitations under the License.
|
* limitations under the License.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
import { RenderingCancelledException, shadow } from "pdfjs-lib";
|
||||||
import { CSS_UNITS } from "./ui_utils.js";
|
import { CSS_UNITS } from "./ui_utils.js";
|
||||||
import { PDFPrintServiceFactory } from "./app.js";
|
import { PDFPrintServiceFactory } from "./app.js";
|
||||||
import { shadow } from "pdfjs-lib";
|
|
||||||
|
|
||||||
// Creates a placeholder with div and canvas with right size for the page.
|
// Creates a placeholder with div and canvas with right size for the page.
|
||||||
function composePage(
|
function composePage(
|
||||||
|
@ -85,8 +85,10 @@ function composePage(
|
||||||
}
|
}
|
||||||
obj.done();
|
obj.done();
|
||||||
},
|
},
|
||||||
function (error) {
|
function (reason) {
|
||||||
console.error(error);
|
if (!(reason instanceof RenderingCancelledException)) {
|
||||||
|
console.error(reason);
|
||||||
|
}
|
||||||
|
|
||||||
if (currentRenderTask === thisRenderTask) {
|
if (currentRenderTask === thisRenderTask) {
|
||||||
currentRenderTask.cancel();
|
currentRenderTask.cancel();
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue