Index: chrome/browser/ui/omnibox/omnibox_edit_model.cc |
diff --git a/chrome/browser/ui/omnibox/omnibox_edit_model.cc b/chrome/browser/ui/omnibox/omnibox_edit_model.cc |
index 188611d51c8d59bf58b73013b81d2d9bb9549725..2fe45b33b05fc4989d36c88a4ef88d586f6ee389 100644 |
--- a/chrome/browser/ui/omnibox/omnibox_edit_model.cc |
+++ b/chrome/browser/ui/omnibox/omnibox_edit_model.cc |
@@ -1009,6 +1009,12 @@ bool OmniboxEditModel::OnAfterPossibleChange(const string16& old_text, |
void OmniboxEditModel::PopupBoundsChangedTo(const gfx::Rect& bounds) { |
InstantController* instant = controller_->GetInstant(); |
if (instant) |
+ instant->SetPopupBounds(bounds); |
+} |
+ |
+void OmniboxEditModel::OmniboxBoundsChangedTo(const gfx::Rect& bounds) { |
+ InstantController* instant = controller_->GetInstant(); |
+ if (instant) |
instant->SetOmniboxBounds(bounds); |
} |
@@ -1045,6 +1051,9 @@ void OmniboxEditModel::OnResultChanged(bool default_match_changed) { |
popup_->OnResultChanged(); |
} |
+ // TODO(melevin): Find a better place to call this. |
+ OmniboxBoundsChangedTo(view_->GetBounds()); |
dhollowa
2012/11/14 17:20:46
The OmniboxView class holds a pointer to an Omnibo
melevin
2012/11/14 22:16:27
Thanks, this is much cleaner.
|
+ |
if (popup_->IsOpen()) { |
PopupBoundsChangedTo(popup_->view()->GetTargetBounds()); |
} else if (was_open) { |