aboutsummaryrefslogtreecommitdiff
path: root/ext/js/pages/settings/dictionary-controller.js
diff options
context:
space:
mode:
authortoasted-nutbread <toasted-nutbread@users.noreply.github.com>2021-04-03 13:32:53 -0400
committerGitHub <noreply@github.com>2021-04-03 13:32:53 -0400
commit0e26d9a667e2794346c8969a24d389eb45208df1 (patch)
tree815bd07d8216c1b9b88c8f7d6f341ab5259b6fd1 /ext/js/pages/settings/dictionary-controller.js
parenta9fe2d03b22a0dd5760019f1325a7a86ebb07b85 (diff)
Remove code for old settings page (#1588)
Diffstat (limited to 'ext/js/pages/settings/dictionary-controller.js')
-rw-r--r--ext/js/pages/settings/dictionary-controller.js25
1 files changed, 0 insertions, 25 deletions
diff --git a/ext/js/pages/settings/dictionary-controller.js b/ext/js/pages/settings/dictionary-controller.js
index 23a47f9a..f000aa62 100644
--- a/ext/js/pages/settings/dictionary-controller.js
+++ b/ext/js/pages/settings/dictionary-controller.js
@@ -47,12 +47,9 @@ class DictionaryEntry {
this._detailsContainer = node.querySelector('.dictionary-details');
const enabledCheckbox = node.querySelector('.dictionary-enabled');
- const allowSecondarySearchesCheckbox = node.querySelector('.dictionary-allow-secondary-searches');
const priorityInput = node.querySelector('.dictionary-priority');
- const deleteButton = node.querySelector('.dictionary-delete-button');
const menuButton = node.querySelector('.dictionary-menu-button');
const detailsTable = node.querySelector('.dictionary-details-table');
- const detailsToggleLink = node.querySelector('.dictionary-details-toggle-link');
const outdatedContainer = node.querySelector('.dictionary-outdated-notification');
const titleNode = node.querySelector('.dictionary-title');
const versionNode = node.querySelector('.dictionary-version');
@@ -69,9 +66,6 @@ class DictionaryEntry {
if (outdatedContainer !== null) {
outdatedContainer.hidden = (version >= 3);
}
- if (detailsToggleLink !== null) {
- detailsToggleLink.hidden = !hasDetails;
- }
if (enabledCheckbox !== null) {
enabledCheckbox.dataset.setting = `dictionaries[${index}].enabled`;
this._eventListeners.addEventListener(enabledCheckbox, 'settingChanged', this._onEnabledChanged.bind(this), false);
@@ -79,19 +73,10 @@ class DictionaryEntry {
if (priorityInput !== null) {
priorityInput.dataset.setting = `dictionaries[${index}].priority`;
}
- if (allowSecondarySearchesCheckbox !== null) {
- allowSecondarySearchesCheckbox.dataset.setting = `dictionaries[${index}].allowSecondarySearches`;
- }
- if (deleteButton !== null) {
- this._eventListeners.addEventListener(deleteButton, 'click', this._onDeleteButtonClicked.bind(this), false);
- }
if (menuButton !== null) {
this._eventListeners.addEventListener(menuButton, 'menuOpen', this._onMenuOpen.bind(this), false);
this._eventListeners.addEventListener(menuButton, 'menuClose', this._onMenuClose.bind(this), false);
}
- if (detailsToggleLink !== null && this._detailsContainer !== null) {
- this._eventListeners.addEventListener(detailsToggleLink, 'click', this._onDetailsToggleLinkClicked.bind(this), false);
- }
}
cleanup() {
@@ -111,11 +96,6 @@ class DictionaryEntry {
// Private
- _onDeleteButtonClicked(e) {
- e.preventDefault();
- this._delete();
- }
-
_onMenuOpen(e) {
const bodyNode = e.detail.menu.bodyNode;
const showDetails = bodyNode.querySelector('.popup-menu-item[data-menu-action="showDetails"]');
@@ -146,11 +126,6 @@ class DictionaryEntry {
}
}
- _onDetailsToggleLinkClicked(e) {
- e.preventDefault();
- this._detailsContainer.hidden = !this._detailsContainer.hidden;
- }
-
_onEnabledChanged(e) {
const {detail: {value}} = e;
this._node.dataset.enabled = `${value}`;