aboutsummaryrefslogtreecommitdiff
path: root/ext/bg/js/search.js
diff options
context:
space:
mode:
authortoasted-nutbread <toasted-nutbread@users.noreply.github.com>2021-01-26 18:30:01 -0500
committerGitHub <noreply@github.com>2021-01-26 18:30:01 -0500
commit8d292363d4d7363134a66e6d35e549f4634521a1 (patch)
tree880cad7f3f2e279401af888335d053c6c80b48cf /ext/bg/js/search.js
parentd11cd7b28f6837c38a566461dc124799ac6736c9 (diff)
Update clipboard options organization (#1318)
* Update options organization * Update general.enableClipboardPopups to clipboard.enableBackgroundMonitor * Update general.enableClipboardMonitor to clipboard.enableSearchPageMonitor * Update general.maximumClipboardSearchLength to clipboard.maximumSearchLength * Update general.autoSearchClipboardContent to clipboard.autoSearchContent
Diffstat (limited to 'ext/bg/js/search.js')
-rw-r--r--ext/bg/js/search.js12
1 files changed, 6 insertions, 6 deletions
diff --git a/ext/bg/js/search.js b/ext/bg/js/search.js
index c17ae1ac..27cba50f 100644
--- a/ext/bg/js/search.js
+++ b/ext/bg/js/search.js
@@ -126,7 +126,7 @@ class DisplaySearch extends Display {
}
_onDisplayOptionsUpdated({options}) {
- this._clipboardMonitorEnabled = options.general.enableClipboardMonitor;
+ this._clipboardMonitorEnabled = options.clipboard.enableSearchPageMonitor;
this._updateClipboardMonitorEnabled();
}
@@ -182,13 +182,13 @@ class DisplaySearch extends Display {
}
_onExternalSearchUpdate({text, animate=true}) {
- const {general: {maximumClipboardSearchLength, autoSearchClipboardContent}} = this.getOptions();
- if (text.length > maximumClipboardSearchLength) {
- text = text.substring(0, maximumClipboardSearchLength);
+ const {clipboard: {autoSearchContent, maximumSearchLength}} = this.getOptions();
+ if (text.length > maximumSearchLength) {
+ text = text.substring(0, maximumSearchLength);
}
this._queryInput.value = text;
this._updateSearchHeight(true);
- this._search(animate, false, autoSearchClipboardContent);
+ this._search(animate, false, autoSearchContent);
}
_onWanakanaEnableChange(e) {
@@ -303,7 +303,7 @@ class DisplaySearch extends Display {
await api.modifySettings([{
action: 'set',
- path: 'general.enableClipboardMonitor',
+ path: 'clipboard.enableSearchPageMonitor',
value,
scope: 'profile',
optionsContext: this.getOptionsContext()