Skip to content

Commit

Permalink
Make "a-z" characters work in filter hints mode.
Browse files Browse the repository at this point in the history
When we read hint characters, we read them lower case.  When we generate
hint markers, we generate them upper case.  So they never match.

(Exactly why anyone would want to use "abcde" for filtered link hints
isn't clear, but at least we should behave correctly.)
  • Loading branch information
smblott-github committed Jun 11, 2015
1 parent 61764d8 commit 53d1317
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion content_scripts/link_hints.coffee
Original file line number Diff line number Diff line change
Expand Up @@ -532,7 +532,7 @@ class FilterHints
# input. use them to filter the link hints accordingly.
matchString = @hintKeystrokeQueue.join ""
linksMatched = @filterLinkHints hintMarkers
linksMatched = linksMatched.filter (linkMarker) -> linkMarker.hintString.startsWith matchString
linksMatched = linksMatched.filter (linkMarker) -> linkMarker.hintString.toLowerCase().startsWith matchString

if linksMatched.length == 1 && @hintKeystrokeQueue.length == 0 and 0 < @linkTextKeystrokeQueue.length
# In filter mode, people tend to type out words past the point needed for a unique match. Hence we
Expand Down

0 comments on commit 53d1317

Please sign in to comment.