aboutsummaryrefslogtreecommitdiff
path: root/html/text_entry_list.js
diff options
context:
space:
mode:
authorWojtek Kosior <koszko@koszko.org>2022-01-25 09:37:34 +0100
committerWojtek Kosior <koszko@koszko.org>2022-01-25 09:37:34 +0100
commitb75a5717a084c9e5a727c2e960f2b910abcb5ace (patch)
treea9dcd00c428aeba011e9a445b96aacad962a1f3d /html/text_entry_list.js
parent7218849ae2f43aee6b3462a30e07caf5bac3d22b (diff)
downloadbrowser-extension-b75a5717a084c9e5a727c2e960f2b910abcb5ace.tar.gz
browser-extension-b75a5717a084c9e5a727c2e960f2b910abcb5ace.zip
add a repo querying HTML interface
Diffstat (limited to 'html/text_entry_list.js')
-rw-r--r--html/text_entry_list.js7
1 files changed, 3 insertions, 4 deletions
diff --git a/html/text_entry_list.js b/html/text_entry_list.js
index 8cef08f..0ea2862 100644
--- a/html/text_entry_list.js
+++ b/html/text_entry_list.js
@@ -162,11 +162,11 @@ function Entry(text, list, entry_idx) {
[this.cancel_but, this.make_noneditable],
[this.noneditable_view, this.make_editable],
])
- node.addEventListener("click", dialog.when_hidden(list.dialog_ctx, cb));
+ node.addEventListener("click", list.dialog_ctx.when_hidden(cb));
const enter_cb = e => (e.key === 'Enter') && enter_hit();
this.input.addEventListener("keypress",
- dialog.when_hidden(list.dialog_ctx, enter_cb));
+ list.dialog_ctx.when_hidden(enter_cb));
if (entry_idx > 0) {
const prev_text = list.shown_texts[entry_idx - 1];
@@ -227,8 +227,7 @@ function TextEntryList(dialog_ctx, destroy_cb,
const add_new = () => new Entry(null, this, 0);
- this.new_but.addEventListener("click",
- dialog.when_hidden(dialog_ctx, add_new));
+ this.new_but.addEventListener("click", dialog_ctx.when_hidden(add_new));
}
async function repo_list(dialog_ctx) {