OLD | NEW |
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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/views/location_bar/location_bar_view.h" | 5 #include "chrome/browser/views/location_bar/location_bar_view.h" |
6 | 6 |
7 #if defined(OS_LINUX) | 7 #if defined(OS_LINUX) |
8 #include <gtk/gtk.h> | 8 #include <gtk/gtk.h> |
9 #endif | 9 #endif |
10 | 10 |
11 #include "app/drag_drop_types.h" | 11 #include "app/drag_drop_types.h" |
12 #include "app/l10n_util.h" | 12 #include "app/l10n_util.h" |
13 #include "app/resource_bundle.h" | 13 #include "app/resource_bundle.h" |
14 #include "app/theme_provider.h" | 14 #include "app/theme_provider.h" |
15 #include "base/stl_util-inl.h" | 15 #include "base/stl_util-inl.h" |
16 #include "base/utf_string_conversions.h" | 16 #include "base/utf_string_conversions.h" |
17 #include "chrome/app/chrome_command_ids.h" | 17 #include "chrome/app/chrome_command_ids.h" |
18 #include "chrome/browser/alternate_nav_url_fetcher.h" | 18 #include "chrome/browser/alternate_nav_url_fetcher.h" |
19 #include "chrome/browser/autocomplete/autocomplete_popup_model.h" | 19 #include "chrome/browser/autocomplete/autocomplete_popup_model.h" |
20 #include "chrome/browser/defaults.h" | 20 #include "chrome/browser/defaults.h" |
21 #include "chrome/browser/extensions/extension_browser_event_router.h" | 21 #include "chrome/browser/extensions/extension_browser_event_router.h" |
22 #include "chrome/browser/extensions/extensions_service.h" | 22 #include "chrome/browser/extensions/extensions_service.h" |
23 #include "chrome/browser/instant/instant_controller.h" | 23 #include "chrome/browser/instant/instant_controller.h" |
24 #include "chrome/browser/profile.h" | 24 #include "chrome/browser/profiles/profile.h" |
25 #include "chrome/browser/renderer_host/render_widget_host_view.h" | 25 #include "chrome/browser/renderer_host/render_widget_host_view.h" |
26 #include "chrome/browser/search_engines/template_url.h" | 26 #include "chrome/browser/search_engines/template_url.h" |
27 #include "chrome/browser/search_engines/template_url_model.h" | 27 #include "chrome/browser/search_engines/template_url_model.h" |
28 #include "chrome/browser/ui/tab_contents/tab_contents_wrapper.h" | 28 #include "chrome/browser/ui/tab_contents/tab_contents_wrapper.h" |
29 #include "chrome/browser/ui/view_ids.h" | 29 #include "chrome/browser/ui/view_ids.h" |
30 #include "chrome/browser/ui/views/location_bar/suggested_text_view.h" | 30 #include "chrome/browser/ui/views/location_bar/suggested_text_view.h" |
31 #include "chrome/browser/ui/views/browser_dialogs.h" | 31 #include "chrome/browser/ui/views/browser_dialogs.h" |
32 #include "chrome/browser/ui/views/location_bar/content_setting_image_view.h" | 32 #include "chrome/browser/ui/views/location_bar/content_setting_image_view.h" |
33 #include "chrome/browser/ui/views/location_bar/ev_bubble_view.h" | 33 #include "chrome/browser/ui/views/location_bar/ev_bubble_view.h" |
34 #include "chrome/browser/ui/views/location_bar/keyword_hint_view.h" | 34 #include "chrome/browser/ui/views/location_bar/keyword_hint_view.h" |
(...skipping 1203 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1238 void LocationBarView::OnTemplateURLModelChanged() { | 1238 void LocationBarView::OnTemplateURLModelChanged() { |
1239 template_url_model_->RemoveObserver(this); | 1239 template_url_model_->RemoveObserver(this); |
1240 template_url_model_ = NULL; | 1240 template_url_model_ = NULL; |
1241 ShowFirstRunBubble(bubble_type_); | 1241 ShowFirstRunBubble(bubble_type_); |
1242 } | 1242 } |
1243 | 1243 |
1244 bool LocationBarView::HasValidSuggestText() { | 1244 bool LocationBarView::HasValidSuggestText() { |
1245 return suggested_text_view_ && !suggested_text_view_->size().IsEmpty() && | 1245 return suggested_text_view_ && !suggested_text_view_->size().IsEmpty() && |
1246 !suggested_text_view_->GetText().empty(); | 1246 !suggested_text_view_->GetText().empty(); |
1247 } | 1247 } |
OLD | NEW |