From 005f9658d98143ea1189482ae627405c8bf5a566 Mon Sep 17 00:00:00 2001 From: toasted-nutbread Date: Sun, 21 Nov 2021 15:54:58 -0500 Subject: Action handler name disambiguation (#2018) * Disambiguate PopupFactory action handlers * Update HotkeyHandler action names * Disambiguate Frontend action handlers * Disambiguate Display action handlers * Disambiguate PopupPreviewFrame action handlers * Disambiguate Yomichan action handlers * Disambiguate Frontend action handlers * Disambiguate Display action handlers * Disambiguate SearchDisplayController action handlers --- ext/js/pages/settings/popup-preview-controller.js | 6 +++--- ext/js/pages/settings/popup-preview-frame.js | 8 ++++---- 2 files changed, 7 insertions(+), 7 deletions(-) (limited to 'ext/js/pages/settings') diff --git a/ext/js/pages/settings/popup-preview-controller.js b/ext/js/pages/settings/popup-preview-controller.js index 2a47d385..9a00c845 100644 --- a/ext/js/pages/settings/popup-preview-controller.js +++ b/ext/js/pages/settings/popup-preview-controller.js @@ -52,16 +52,16 @@ class PopupPreviewController { } _onCustomCssChange() { - this._invoke('setCustomCss', {css: this._customCss.value}); + this._invoke('PopupPreviewFrame.setCustomCss', {css: this._customCss.value}); } _onCustomOuterCssChange() { - this._invoke('setCustomOuterCss', {css: this._customOuterCss.value}); + this._invoke('PopupPreviewFrame.setCustomOuterCss', {css: this._customOuterCss.value}); } _onOptionsContextChange() { const optionsContext = this._settingsController.getOptionsContext(); - this._invoke('updateOptionsContext', {optionsContext}); + this._invoke('PopupPreviewFrame.updateOptionsContext', {optionsContext}); } _invoke(action, params) { diff --git a/ext/js/pages/settings/popup-preview-frame.js b/ext/js/pages/settings/popup-preview-frame.js index 638dd414..2b29d5b9 100644 --- a/ext/js/pages/settings/popup-preview-frame.js +++ b/ext/js/pages/settings/popup-preview-frame.js @@ -38,10 +38,10 @@ class PopupPreviewFrame { this._targetOrigin = chrome.runtime.getURL('/').replace(/\/$/, ''); this._windowMessageHandlers = new Map([ - ['setText', this._onSetText.bind(this)], - ['setCustomCss', this._setCustomCss.bind(this)], - ['setCustomOuterCss', this._setCustomOuterCss.bind(this)], - ['updateOptionsContext', this._updateOptionsContext.bind(this)] + ['PopupPreviewFrame.setText', this._onSetText.bind(this)], + ['PopupPreviewFrame.setCustomCss', this._setCustomCss.bind(this)], + ['PopupPreviewFrame.setCustomOuterCss', this._setCustomOuterCss.bind(this)], + ['PopupPreviewFrame.updateOptionsContext', this._updateOptionsContext.bind(this)] ]); } -- cgit v1.2.3