From b2758c302307706c91744cc1bc04adb64ff9b73e Mon Sep 17 00:00:00 2001 From: Jonas Jenwald Date: Tue, 6 Apr 2021 13:04:23 +0200 Subject: [PATCH] Remove the deprecated properties from the "presentationmodechanged" event (PR 12788 follow-up) These properties have been deprecated in two releases now, hence we shouldn't need to keep this code around. --- web/pdf_presentation_mode.js | 26 ++++---------------------- 1 file changed, 4 insertions(+), 22 deletions(-) diff --git a/web/pdf_presentation_mode.js b/web/pdf_presentation_mode.js index fd16f5a63..6fb788e14 100644 --- a/web/pdf_presentation_mode.js +++ b/web/pdf_presentation_mode.js @@ -155,28 +155,10 @@ class PDFPresentationMode { } else if (this.active) { state = PresentationModeState.FULLSCREEN; } - - if (typeof PDFJSDev !== "undefined" && PDFJSDev.test("MOZCENTRAL")) { - this.eventBus.dispatch("presentationmodechanged", { - source: this, - state, - }); - } else { - this.eventBus.dispatch("presentationmodechanged", { - source: this, - state, - get active() { - throw new Error( - "Deprecated parameter: `active`, please use `state` instead." - ); - }, - get switchInProgress() { - throw new Error( - "Deprecated parameter: `switchInProgress`, please use `state` instead." - ); - }, - }); - } + this.eventBus.dispatch("presentationmodechanged", { + source: this, + state, + }); } /**