Omnibox: Revise CopyOldMatches Scoring Code
commitc28dea47c62e8205e3dc95a3cb444117216dae57
authormpearson <mpearson@chromium.org>
Fri, 10 Apr 2015 21:30:39 +0000 (10 14:30 -0700)
committerCommit bot <commit-bot@chromium.org>
Fri, 10 Apr 2015 21:31:04 +0000 (10 21:31 +0000)
treeb124edb5bd9cb4e4d116b34c93a395077d1a0dbb
parent87378d90a91b001e4f5c6f9f8a6a5d635d9075b3
Omnibox: Revise CopyOldMatches Scoring Code

The previous code set score caps too high, thus possibly allowing old matches
to outrank all new allowed-to-be-default matches.  This revises the old-match-
preserving code so as it to guarantee that old matches never end up as the
default match.  This is done through score manipulation, not due to explicit
mucking with allowed_to_be_default_match, which may have unintended side
effects due to dup elimination.

BUG=472997

Review URL: https://codereview.chromium.org/1072653002

Cr-Commit-Position: refs/heads/master@{#324685}
components/omnibox/autocomplete_result.cc
components/omnibox/autocomplete_result_unittest.cc