<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40"><head><META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=us-ascii"><meta name=Generator content="Microsoft Word 15 (filtered medium)"><style><!--
/* Font Definitions */
@font-face
        {font-family:"Cambria Math";
        panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0in;
        margin-bottom:.0001pt;
        font-size:11.0pt;
        font-family:"Calibri",sans-serif;}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:purple;
        text-decoration:underline;}
p.msonormal0, li.msonormal0, div.msonormal0
        {mso-style-name:msonormal;
        mso-margin-top-alt:auto;
        margin-right:0in;
        mso-margin-bottom-alt:auto;
        margin-left:0in;
        font-size:11.0pt;
        font-family:"Calibri",sans-serif;}
span.EmailStyle18
        {mso-style-type:personal-reply;
        font-family:"Calibri",sans-serif;
        color:windowtext;}
.MsoChpDefault
        {mso-style-type:export-only;
        font-size:10.0pt;}
@page WordSection1
        {size:8.5in 11.0in;
        margin:1.0in 1.0in 1.0in 1.0in;}
div.WordSection1
        {page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]--></head><body lang=EN-US link=blue vlink=purple><div class=WordSection1><p class=MsoNormal>Thanks Anthony for more information.<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>We have reopened the bug with details.<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>Regards,<o:p></o:p></p><p class=MsoNormal>Muneer<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><div><div style='border:none;border-top:solid #E1E1E1 1.0pt;padding:3.0pt 0in 0in 0in'><p class=MsoNormal><b>From:</b> Anthony Vanelverdinghe <anthonyv.be@outlook.com> <br><b>Sent:</b> Monday, September 10, 2018 2:49 PM<br><b>To:</b> quality-discuss@openjdk.java.net<br><b>Subject:</b> JDK-8210405 is reproducible and should be reopened<o:p></o:p></p></div></div><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>Hi<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>Recently I filed an issue with the Javadoc search in Microsft Edge [https://bugs.openjdk.java.net/browse/JDK-8210405]. This was closed as unreproducible, but I can consistently reproduce this on multiple PCs.<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>The problem is as follows: hitting Enter in the search field, selects the first result in the autocompletion list. Now, in Microsoft Edge, the autocompletion list doesn’t update fast enough, so if you quickly type “String” and hit Enter, you won’t be redirected to java.lang.String as expected.<o:p></o:p></p><p class=MsoNormal>I looked into this myself, and with the changes below, the bug is no longer reproducible. Now when you hit Enter, a new search is triggered and the first result of this search is used for navigation.<o:p></o:p></p><p class=MsoNormal>I don’t know if the root cause is a bug in Microsoft Edge, jQuery UI, or the Javadoc Search’s usage of jQuery UI, but this shows that there is an issue, and that a solution is possible, solely by changing the Javadoc Search implementation.<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>So my question is to reopen this issue and append the given information to it. Thanks in advance.<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>Here’s what I did in search.js:<o:p></o:p></p><p class=MsoNormal>1) add a global variable:<o:p></o:p></p><p class=MsoNormal>    var selectRequested = false;<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>2) inside $("#search").catcomplete(...), change the “select” property by extracting the current code into a global function:<o:p></o:p></p><p class=MsoNormal>    function navigateToItem(ui) {<o:p></o:p></p><p class=MsoNormal>        // ...<o:p></o:p></p><p class=MsoNormal>    }<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>And change the implementation as follows:<o:p></o:p></p><p class=MsoNormal>    select: function(event, ui) {<o:p></o:p></p><p class=MsoNormal>        if(event.key === "Enter") {<o:p></o:p></p><p class=MsoNormal>            selectRequested = true;<o:p></o:p></p><p class=MsoNormal>            $("#search").catcomplete("search", $("#search").val());<o:p></o:p></p><p class=MsoNormal>        } else {<o:p></o:p></p><p class=MsoNormal>            navigateToItem(ui);<o:p></o:p></p><p class=MsoNormal>        }<o:p></o:p></p><p class=MsoNormal>    }<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>3) still inside $("#search").catcomplete(...), change the “response” property by appending the following to it:<o:p></o:p></p><p class=MsoNormal>    if(selectRequested) {<o:p></o:p></p><p class=MsoNormal>        navigateToItem({item: ui.content[0]});<o:p></o:p></p><p class=MsoNormal>    }<o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>Kind regards,<o:p></o:p></p><p class=MsoNormal>Anthony Vanelverdinghe<o:p></o:p></p></div></body></html>