diff options
Diffstat (limited to 'templates/html/htmlsearchresult.tpl')
-rw-r--r-- | templates/html/htmlsearchresult.tpl | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/templates/html/htmlsearchresult.tpl b/templates/html/htmlsearchresult.tpl index db37a5d..4e15414 100644 --- a/templates/html/htmlsearchresult.tpl +++ b/templates/html/htmlsearchresult.tpl @@ -24,6 +24,12 @@ document.getElementById("Loading").style.display="none"; document.getElementById("NoMatches").style.display="none"; var searchResults = new SearchResults("searchResults"); searchResults.Search(); +window.addEventListener("message", function(event) { + if (event.data == "take_focus") { + var elem = searchResults.NavNext(0); + if (elem) elem.focus(); + } +}); /* @license-end */ --></script> </div> |