Adds three keyboard shortcuts to report.html
to make navigation faster:
Jump to next path: j
Jump to previous path: k
Show Help: ?
Differential D13134
[analyzer] Add keyboard shortcuts to report.html
dcoughlin on Sep 24 2015, 7:24 AM. Authored by
Details
Adds three keyboard shortcuts to report.html Jump to next path: j
Diff Detail Event TimelineComment Actions Thanks for the patch! This looks very useful. What browsers does the JavaScript support? One thing I noticed is that after immediately loading a new report page the 'j' and 'k' shortcuts don't work for me. In Safari, I get: TypeError: null is not an object (evaluating 'document.location.hash.match(/Path\d+|EndPath/)') Jumpkeyboard-shortcuts.js:3 onkeydownkeyboard-shortcuts.js:29 After clicking on the location link in the summary the keys do work. (I guess this has to with the # in the location?) Would it be possible to make these navigation keys go to the end of the path after the page has loaded but before the user has clicked on the location link?
Comment Actions Included mousetrap to get keyboard shortcuts working on all international keyboards. Comment Actions Thanks for the update. Unfortunately, we can't accept the mousetrap code. Any code contributed to clang needs to be under the UIUC license. The original copyright owner would need to contribute the code under that license. I think it would be fine to revert to your previous version -- but with a FIXME stating that this doesn't work on non-QWERTY keyboards. Other than that, this LGTM. |
Will this work on international keyboards where ? is not Shift + '/'? (E.g., AZERTY or QWERTZ?)