Remove the find bar's dependency on the find controller

Pull request #10100 removed the last usage of the find controller from
the find bar, so we can drop the dependency now.
This commit is contained in:
Tim van der Meij 2018-09-21 16:11:59 +02:00
parent ba172c7d03
commit 7aca53b1a4
No known key found for this signature in database
GPG Key ID: 8C3FD2925A5F2762
2 changed files with 0 additions and 7 deletions

View File

@ -369,7 +369,6 @@ let PDFViewerApplication = {
// TODO: improve `PDFFindBar` constructor parameter passing
let findBarConfig = Object.create(appConfig.findBar);
findBarConfig.findController = this.findController;
findBarConfig.eventBus = eventBus;
this.findBar = new PDFFindBar(findBarConfig, this.l10n);

View File

@ -38,15 +38,9 @@ class PDFFindBar {
this.findResultsCount = options.findResultsCount || null;
this.findPreviousButton = options.findPreviousButton || null;
this.findNextButton = options.findNextButton || null;
this.findController = options.findController || null;
this.eventBus = options.eventBus;
this.l10n = l10n;
if (this.findController === null) {
throw new Error('PDFFindBar cannot be used without a ' +
'PDFFindController instance.');
}
// Add event listeners to the DOM elements.
this.toggleButton.addEventListener('click', () => {
this.toggle();