summaryrefslogtreecommitdiffstats
path: root/chrome/browser/rlz
diff options
context:
space:
mode:
authorsky@chromium.org <sky@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-10-21 19:11:39 +0000
committersky@chromium.org <sky@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-10-21 19:11:39 +0000
commiteac60f73ccc4dec42784ee6237f73ec4fa69ed7a (patch)
treefc530b579733cdc737fa9b6d3b3b76ae686358f2 /chrome/browser/rlz
parentfde4f5840faa877d5489b28e45f6058620336c7d (diff)
downloadchromium_src-eac60f73ccc4dec42784ee6237f73ec4fa69ed7a.zip
chromium_src-eac60f73ccc4dec42784ee6237f73ec4fa69ed7a.tar.gz
chromium_src-eac60f73ccc4dec42784ee6237f73ec4fa69ed7a.tar.bz2
Makes RLZ listen for changes to instant so that it can update at the
right time. BUG=56259 TEST=none Review URL: http://codereview.chromium.org/3969004 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@63393 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/rlz')
-rw-r--r--chrome/browser/rlz/rlz.cc4
1 files changed, 4 insertions, 0 deletions
diff --git a/chrome/browser/rlz/rlz.cc b/chrome/browser/rlz/rlz.cc
index 840ce60..2ba1ed0 100644
--- a/chrome/browser/rlz/rlz.cc
+++ b/chrome/browser/rlz/rlz.cc
@@ -66,6 +66,10 @@ class OmniBoxUsageObserver : public NotificationObserver {
OmniBoxUsageObserver() {
registrar_.Add(this, NotificationType::OMNIBOX_OPENED_URL,
NotificationService::AllSources());
+ // If instant is enabled we'll start searching as soon as the user starts
+ // typing in the omnibox (which triggers INSTANT_CONTROLLER_UPDATED).
+ registrar_.Add(this, NotificationType::INSTANT_CONTROLLER_UPDATED,
+ NotificationService::AllSources());
omnibox_used_ = false;
DCHECK(!instance_);
instance_ = this;