From ce49a47906658f04537e25406d429de38cb99119 Mon Sep 17 00:00:00 2001 From: "estade@chromium.org" Date: Tue, 7 Dec 2010 03:43:25 +0000 Subject: Re-load instant results when user text has whitespace changes. BUG=65688 TEST=see bug Review URL: http://codereview.chromium.org/5657002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@68438 0039d316-1c4b-4281-b951-d872f2087c98 --- chrome/browser/instant/instant_loader.cc | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'chrome/browser/instant/instant_loader.cc') diff --git a/chrome/browser/instant/instant_loader.cc b/chrome/browser/instant/instant_loader.cc index af76f34..40954d3 100644 --- a/chrome/browser/instant/instant_loader.cc +++ b/chrome/browser/instant/instant_loader.cc @@ -480,8 +480,12 @@ void InstantLoader::Update(TabContentsWrapper* tab_contents, // modifies the text of the omnibox in anyway the URL changes. We also need to // update if verbatim changes and we're showing instant results. We have to be // careful in checking user_text as in some situations InstantController - // passes in an empty string (when it knows the user_text won't matter). - if (url_ == url && (!template_url || verbatim == verbatim_)) { + // passes in an empty string (when it knows the user_text won't matter). In + // these cases, we don't worry about whether the new user text matches the old + // user text. + if ((url_ == url) && + (new_user_text.empty() || user_text_ == new_user_text) && + (!template_url || verbatim == verbatim_)) { suggested_text->assign(last_suggestion_); return; } -- cgit v1.1