| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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/ui/views/location_bar/location_bar_view.h" | 5 #include "chrome/browser/ui/views/location_bar/location_bar_view.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 #include <map> | 8 #include <map> |
| 9 | 9 |
| 10 #include "base/i18n/rtl.h" | 10 #include "base/i18n/rtl.h" |
| (...skipping 801 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 812 omnibox_view_->ResetTabState(contents); | 812 omnibox_view_->ResetTabState(contents); |
| 813 } | 813 } |
| 814 | 814 |
| 815 //////////////////////////////////////////////////////////////////////////////// | 815 //////////////////////////////////////////////////////////////////////////////// |
| 816 // LocationBarView, public OmniboxEditController implementation: | 816 // LocationBarView, public OmniboxEditController implementation: |
| 817 | 817 |
| 818 void LocationBarView::UpdateWithoutTabRestore() { | 818 void LocationBarView::UpdateWithoutTabRestore() { |
| 819 Update(nullptr); | 819 Update(nullptr); |
| 820 } | 820 } |
| 821 | 821 |
| 822 void LocationBarView::ShowURL() { | |
| 823 omnibox_view_->ShowURL(); | |
| 824 } | |
| 825 | |
| 826 ToolbarModel* LocationBarView::GetToolbarModel() { | 822 ToolbarModel* LocationBarView::GetToolbarModel() { |
| 827 return delegate_->GetToolbarModel(); | 823 return delegate_->GetToolbarModel(); |
| 828 } | 824 } |
| 829 | 825 |
| 830 WebContents* LocationBarView::GetWebContents() { | 826 WebContents* LocationBarView::GetWebContents() { |
| 831 return delegate_->GetWebContents(); | 827 return delegate_->GetWebContents(); |
| 832 } | 828 } |
| 833 | 829 |
| 834 //////////////////////////////////////////////////////////////////////////////// | 830 //////////////////////////////////////////////////////////////////////////////// |
| 835 // LocationBarView, private: | 831 // LocationBarView, private: |
| (...skipping 565 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1401 // LocationBarView, private TemplateURLServiceObserver implementation: | 1397 // LocationBarView, private TemplateURLServiceObserver implementation: |
| 1402 | 1398 |
| 1403 void LocationBarView::OnTemplateURLServiceChanged() { | 1399 void LocationBarView::OnTemplateURLServiceChanged() { |
| 1404 template_url_service_->RemoveObserver(this); | 1400 template_url_service_->RemoveObserver(this); |
| 1405 template_url_service_ = nullptr; | 1401 template_url_service_ = nullptr; |
| 1406 // If the browser is no longer active, let's not show the info bubble, as this | 1402 // If the browser is no longer active, let's not show the info bubble, as this |
| 1407 // would make the browser the active window again. | 1403 // would make the browser the active window again. |
| 1408 if (omnibox_view_ && omnibox_view_->GetWidget()->IsActive()) | 1404 if (omnibox_view_ && omnibox_view_->GetWidget()->IsActive()) |
| 1409 ShowFirstRunBubble(); | 1405 ShowFirstRunBubble(); |
| 1410 } | 1406 } |
| OLD | NEW |