aboutsummaryrefslogtreecommitdiff
path: root/ext/bg/js/options.js
diff options
context:
space:
mode:
authorAlex Yatskov <alex@foosoft.net>2017-03-11 17:48:30 -0800
committerAlex Yatskov <alex@foosoft.net>2017-03-11 17:48:30 -0800
commit83e2fd47485f7036c387563277db06aec14aa462 (patch)
treed0335ae917308dcb22bef19ad6b909cfd3f4b366 /ext/bg/js/options.js
parent2c86e875765b1ed4f1753ab51af5583cc9606760 (diff)
add options for setting popup width, height, offset
Diffstat (limited to 'ext/bg/js/options.js')
-rw-r--r--ext/bg/js/options.js6
1 files changed, 6 insertions, 0 deletions
diff --git a/ext/bg/js/options.js b/ext/bg/js/options.js
index 3b10b74f..a094f73f 100644
--- a/ext/bg/js/options.js
+++ b/ext/bg/js/options.js
@@ -30,6 +30,9 @@ function formRead() {
optionsNew.general.softKatakana = $('#soft-katakana-search').prop('checked');
optionsNew.general.showAdvanced = $('#show-advanced-options').prop('checked');
optionsNew.general.maxResults = parseInt($('#max-displayed-results').val(), 10);
+ optionsNew.general.popupWidth = parseInt($('#popup-width').val(), 10);
+ optionsNew.general.popupHeight = parseInt($('#popup-height').val(), 10);
+ optionsNew.general.popupOffset = parseInt($('#popup-offset').val(), 10);
optionsNew.scanning.requireShift = $('#hold-shift-to-scan').prop('checked');
optionsNew.scanning.middleMouse = $('#middle-mouse-button-scan').prop('checked');
@@ -112,6 +115,9 @@ $(document).ready(() => {
$('#soft-katakana-search').prop('checked', options.general.softKatakana);
$('#show-advanced-options').prop('checked', options.general.showAdvanced);
$('#max-displayed-results').val(options.general.maxResults);
+ $('#popup-width').val(options.general.popupWidth);
+ $('#popup-height').val(options.general.popupHeight);
+ $('#popup-offset').val(options.general.popupOffset);
$('#hold-shift-to-scan').prop('checked', options.scanning.requireShift);
$('#middle-mouse-button-scan').prop('checked', options.scanning.middleMouse);