| 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..2194e635519254976020b142a74c3bdc16895a49 100644
|
| --- a/chrome/browser/ui/omnibox/omnibox_edit_model.cc
|
| +++ b/chrome/browser/ui/omnibox/omnibox_edit_model.cc
|
| @@ -1006,10 +1006,16 @@ bool OmniboxEditModel::OnAfterPossibleChange(const string16& old_text,
|
| MaybeAcceptKeywordBySpace(user_text_));
|
| }
|
|
|
| -void OmniboxEditModel::PopupBoundsChangedTo(const gfx::Rect& bounds) {
|
| +void OmniboxEditModel::OnPopupBoundsChanged(const gfx::Rect& bounds) {
|
| InstantController* instant = controller_->GetInstant();
|
| if (instant)
|
| - instant->SetOmniboxBounds(bounds);
|
| + instant->SetPopupBounds(bounds);
|
| +}
|
| +
|
| +void OmniboxEditModel::OnOmniboxBoundsChanged(const gfx::Rect& bounds) {
|
| + InstantController* instant = controller_->GetInstant();
|
| + if (instant)
|
| + instant->SetMarginSize(bounds.x(), bounds.x() + bounds.width());
|
| }
|
|
|
| void OmniboxEditModel::OnResultChanged(bool default_match_changed) {
|
| @@ -1046,14 +1052,14 @@ void OmniboxEditModel::OnResultChanged(bool default_match_changed) {
|
| }
|
|
|
| if (popup_->IsOpen()) {
|
| - PopupBoundsChangedTo(popup_->view()->GetTargetBounds());
|
| + OnPopupBoundsChanged(popup_->view()->GetTargetBounds());
|
| } else if (was_open) {
|
| // Accepts the temporary text as the user text, because it makes little
|
| // sense to have temporary text when the popup is closed.
|
| InternalSetUserText(UserTextFromDisplayText(view_->GetText()));
|
| has_temporary_text_ = false;
|
| is_temporary_text_set_by_instant_ = false;
|
| - PopupBoundsChangedTo(gfx::Rect());
|
| + OnPopupBoundsChanged(gfx::Rect());
|
| NotifySearchTabHelper();
|
| }
|
|
|
|
|