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

Side by Side Diff: chrome/browser/android/omnibox/autocomplete_controller_android.cc

Issue 795343002: Omnibox Watcher: Don't Flag Incidents that are Paste+Enter (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix rlz unittest Created 6 years 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/omnibox/omnibox_log.h » ('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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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/android/omnibox/autocomplete_controller_android.h" 5 #include "chrome/browser/android/omnibox/autocomplete_controller_android.h"
6 6
7 #include "base/android/jni_android.h" 7 #include "base/android/jni_android.h"
8 #include "base/android/jni_string.h" 8 #include "base/android/jni_string.h"
9 #include "base/prefs/pref_service.h" 9 #include "base/prefs/pref_service.h"
10 #include "base/strings/string16.h" 10 #include "base/strings/string16.h"
(...skipping 205 matching lines...) Expand 10 before | Expand all | Expand 10 after
216 content::WebContents* web_contents = 216 content::WebContents* web_contents =
217 content::WebContents::FromJavaWebContents(j_web_contents); 217 content::WebContents::FromJavaWebContents(j_web_contents);
218 218
219 OmniboxLog log( 219 OmniboxLog log(
220 input_.text(), 220 input_.text(),
221 false, /* don't know */ 221 false, /* don't know */
222 input_.type(), 222 input_.type(),
223 true, 223 true,
224 selected_index, 224 selected_index,
225 false, 225 false,
226 false, /* don't know */
226 SessionTabHelper::IdForTab(web_contents), 227 SessionTabHelper::IdForTab(web_contents),
227 current_page_classification, 228 current_page_classification,
228 base::TimeDelta::FromMilliseconds(elapsed_time_since_first_modified), 229 base::TimeDelta::FromMilliseconds(elapsed_time_since_first_modified),
229 base::string16::npos, 230 base::string16::npos,
230 now - autocomplete_controller_->last_time_default_match_changed(), 231 now - autocomplete_controller_->last_time_default_match_changed(),
231 autocomplete_controller_->result()); 232 autocomplete_controller_->result());
232 autocomplete_controller_->AddProvidersInfo(&log.providers_info); 233 autocomplete_controller_->AddProvidersInfo(&log.providers_info);
233 234
234 content::NotificationService::current()->Notify( 235 content::NotificationService::current()->Notify(
235 chrome::NOTIFICATION_OMNIBOX_OPENED_URL, 236 chrome::NOTIFICATION_OMNIBOX_OPENED_URL,
(...skipping 319 matching lines...) Expand 10 before | Expand all | Expand 10 after
555 return; 556 return;
556 557
557 // ZeroSuggestPrefetcher deletes itself after it's done prefetching. 558 // ZeroSuggestPrefetcher deletes itself after it's done prefetching.
558 new ZeroSuggestPrefetcher(profile); 559 new ZeroSuggestPrefetcher(profile);
559 } 560 }
560 561
561 // Register native methods 562 // Register native methods
562 bool RegisterAutocompleteControllerAndroid(JNIEnv* env) { 563 bool RegisterAutocompleteControllerAndroid(JNIEnv* env) {
563 return RegisterNativesImpl(env); 564 return RegisterNativesImpl(env);
564 } 565 }
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/omnibox/omnibox_log.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698