diff options
author | Alex Yatskov <alex@foosoft.net> | 2016-05-01 21:18:28 -0700 |
---|---|---|
committer | Alex Yatskov <alex@foosoft.net> | 2016-05-01 21:18:28 -0700 |
commit | eaa7291683604895017c67e716f7ee44a1ea853a (patch) | |
tree | 355b18ec73e05bb3a666d99cf92ae32aa35f28ce /ext/bg/js/options-form.js | |
parent | 61993db7026d2e06666ba6aeea1f7eed388d8592 (diff) |
Updating options page
Diffstat (limited to 'ext/bg/js/options-form.js')
-rw-r--r-- | ext/bg/js/options-form.js | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/ext/bg/js/options-form.js b/ext/bg/js/options-form.js index bc21793e..9799f664 100644 --- a/ext/bg/js/options-form.js +++ b/ext/bg/js/options-form.js @@ -18,16 +18,18 @@ function optionsToForm(opts) { - $('#scanLength').val(opts.scanLength); + $('#enableAnkiConnect').prop('checked', opts.ankiConnect); + $('#selectMatchedText').prop('checked', opts.selectMatchedText); $('#loadOnStartup').prop('checked', opts.loadOnStartup); - $('#highlightText').prop('checked', opts.highlightText); + $('#scanLength').val(opts.scanLength); } function formToOptions() { return sanitizeOptions({ - scanLength: $('#scanLength').val(), - loadOnStartup: $('#loadOnStartup').prop('checked'), - highlightText: $('#highlightText').prop('checked') + loadOnStartup: $('#loadOnStartup').prop('checked'), + selectMatchedText: $('#selectMatchedText').prop('checked'), + ankiConnect: $('#enableAnkiConnect').prop('checked'), + scanLength: $('#scanLength').val() }); } |