Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1090)

Side by Side Diff: chrome/browser/predictors/autocomplete_action_predictor.cc

Issue 2275953002: Prerender: Remove deprecated prerender experiment histograms. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: trim a few more unsued ones Created 4 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « no previous file | chrome/browser/prerender/prerender_histograms.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/browser/predictors/autocomplete_action_predictor.h" 5 #include "chrome/browser/predictors/autocomplete_action_predictor.h"
6 6
7 #include <math.h> 7 #include <math.h>
8 #include <stddef.h> 8 #include <stddef.h>
9 9
10 #include <vector> 10 #include <vector>
(...skipping 228 matching lines...) Expand 10 before | Expand all | Expand 10 after
239 239
240 // Abandon the current prerender. If it is to be used, it will be used very 240 // Abandon the current prerender. If it is to be used, it will be used very
241 // soon, so use the lower timeout. 241 // soon, so use the lower timeout.
242 if (prerender_handle_) { 242 if (prerender_handle_) {
243 prerender_handle_->OnNavigateAway(); 243 prerender_handle_->OnNavigateAway();
244 // Don't release |prerender_handle_| so it is canceled if it survives to the 244 // Don't release |prerender_handle_| so it is canceled if it survives to the
245 // next StartPrerendering call. 245 // next StartPrerendering call.
246 } 246 }
247 247
248 UMA_HISTOGRAM_BOOLEAN( 248 UMA_HISTOGRAM_BOOLEAN(
249 base::StringPrintf("Prerender.OmniboxNavigationsCouldPrerender%s", 249 "Prerender.OmniboxNavigationsCouldPrerender",
250 prerender::PrerenderManager::GetModeString()).c_str(),
251 prerender::IsOmniboxEnabled(profile_)); 250 prerender::IsOmniboxEnabled(profile_));
252 251
253 const AutocompleteMatch& match = log.result.match_at(log.selected_index); 252 const AutocompleteMatch& match = log.result.match_at(log.selected_index);
254 const GURL& opened_url = match.destination_url; 253 const GURL& opened_url = match.destination_url;
255 const base::string16 lower_user_text(base::i18n::ToLower(log.text)); 254 const base::string16 lower_user_text(base::i18n::ToLower(log.text));
256 255
257 // Traverse transitional matches for those that have a user_text that is a 256 // Traverse transitional matches for those that have a user_text that is a
258 // prefix of |lower_user_text|. 257 // prefix of |lower_user_text|.
259 std::vector<AutocompleteActionPredictorTable::Row> rows_to_add; 258 std::vector<AutocompleteActionPredictorTable::Row> rows_to_add;
260 std::vector<AutocompleteActionPredictorTable::Row> rows_to_update; 259 std::vector<AutocompleteActionPredictorTable::Row> rows_to_update;
(...skipping 328 matching lines...) Expand 10 before | Expand all | Expand 10 after
589 AutocompleteActionPredictor::TransitionalMatch::TransitionalMatch() { 588 AutocompleteActionPredictor::TransitionalMatch::TransitionalMatch() {
590 } 589 }
591 590
592 AutocompleteActionPredictor::TransitionalMatch::TransitionalMatch( 591 AutocompleteActionPredictor::TransitionalMatch::TransitionalMatch(
593 const TransitionalMatch& other) = default; 592 const TransitionalMatch& other) = default;
594 593
595 AutocompleteActionPredictor::TransitionalMatch::~TransitionalMatch() { 594 AutocompleteActionPredictor::TransitionalMatch::~TransitionalMatch() {
596 } 595 }
597 596
598 } // namespace predictors 597 } // namespace predictors
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/prerender/prerender_histograms.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698