changed: use prompt for grep

This commit is contained in:
quenousimporte 2023-10-23 13:27:38 +02:00
parent b33b85f8ee
commit 1328d77cdc
1 changed files with 3 additions and 12 deletions

15
main.js
View File

@ -1650,19 +1650,10 @@ function showgrepresult(grepresult)
function showgrep()
{
filteredlist.hidden = true;
searchdialog.hidden = false;
filter.focus();
filter.select();
filter.onkeydown = function()
var text = prompt("Search:");
if (text)
{
if (event.key === "Enter")
{
event.preventDefault();
searchdialog.hidden = true;
showgrepresult(grep(filter.value));
}
showgrepresult(grep(text));
}
}