| Index: chrome/browser/autocomplete/history_quick_provider.h
|
| diff --git a/chrome/browser/autocomplete/history_quick_provider.h b/chrome/browser/autocomplete/history_quick_provider.h
|
| index bd7a8244acba8d84250f0083e1d5c278ef5ed19c..a77c34396c4e89eda52674783b40b9bc551784fb 100644
|
| --- a/chrome/browser/autocomplete/history_quick_provider.h
|
| +++ b/chrome/browser/autocomplete/history_quick_provider.h
|
| @@ -49,9 +49,11 @@ class HistoryQuickProvider : public HistoryProvider {
|
| static const int kMaxNonInliningScore;
|
|
|
| // Creates an AutocompleteMatch from |history_match|. |max_match_score| gives
|
| - // the maximum possible score for the match.
|
| + // the maximum possible score for the match. |history_matches| is the full set
|
| + // of matches to compare each match to when calculating confidence.
|
| AutocompleteMatch QuickMatchToACMatch(
|
| const history::ScoredHistoryMatch& history_match,
|
| + const history::ScoredHistoryMatches& history_matches,
|
| bool prevent_inline_autocomplete,
|
| int* max_match_score);
|
|
|
| @@ -64,6 +66,12 @@ class HistoryQuickProvider : public HistoryProvider {
|
| const history::ScoredHistoryMatch& history_match,
|
| int* max_match_score);
|
|
|
| + // Determines the confidence of |match| by comparing the |raw_score| to the
|
| + // sum of the scores of |matches|. Returns a float in the range [0, 1].
|
| + static float CalculateConfidence(
|
| + const history::ScoredHistoryMatch& match,
|
| + const history::ScoredHistoryMatches& matches);
|
| +
|
| // Returns the index that should be used for history lookups.
|
| history::InMemoryURLIndex* GetIndex();
|
|
|
|
|