OLD | NEW |
1 // Copyright 2012 The Chromium Authors. All rights reserved. | 1 // Copyright 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 #import "chrome/browser/ui/cocoa/location_bar/location_bar_view_mac.h" | 5 #import "chrome/browser/ui/cocoa/location_bar/location_bar_view_mac.h" |
6 | 6 |
7 #include "base/bind.h" | 7 #include "base/bind.h" |
8 #include "base/command_line.h" | 8 #include "base/command_line.h" |
9 #include "base/message_loop/message_loop.h" | 9 #include "base/message_loop/message_loop.h" |
10 #include "base/prefs/pref_service.h" | 10 #include "base/prefs/pref_service.h" |
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
69 #include "extensions/browser/extension_system.h" | 69 #include "extensions/browser/extension_system.h" |
70 #include "extensions/common/extension.h" | 70 #include "extensions/common/extension.h" |
71 #include "extensions/common/permissions/permissions_data.h" | 71 #include "extensions/common/permissions/permissions_data.h" |
72 #include "grit/component_scaled_resources.h" | 72 #include "grit/component_scaled_resources.h" |
73 #include "grit/generated_resources.h" | 73 #include "grit/generated_resources.h" |
74 #include "grit/theme_resources.h" | 74 #include "grit/theme_resources.h" |
75 #include "net/base/net_util.h" | 75 #include "net/base/net_util.h" |
76 #include "skia/ext/skia_utils_mac.h" | 76 #include "skia/ext/skia_utils_mac.h" |
77 #import "ui/base/cocoa/cocoa_base_utils.h" | 77 #import "ui/base/cocoa/cocoa_base_utils.h" |
78 #include "ui/base/l10n/l10n_util_mac.h" | 78 #include "ui/base/l10n/l10n_util_mac.h" |
79 #include "ui/base/resource/resource_bundle.h" | |
80 #include "ui/gfx/image/image.h" | 79 #include "ui/gfx/image/image.h" |
81 | 80 |
82 using content::WebContents; | 81 using content::WebContents; |
83 | 82 |
84 namespace { | 83 namespace { |
85 | 84 |
86 // Vertical space between the bottom edge of the location_bar and the first run | 85 // Vertical space between the bottom edge of the location_bar and the first run |
87 // bubble arrow point. | 86 // bubble arrow point. |
88 const static int kFirstRunBubbleYOffset = 1; | 87 const static int kFirstRunBubbleYOffset = 1; |
89 | 88 |
(...skipping 714 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
804 } | 803 } |
805 | 804 |
806 bool LocationBarViewMac::UpdateMicSearchDecorationVisibility() { | 805 bool LocationBarViewMac::UpdateMicSearchDecorationVisibility() { |
807 bool is_visible = !GetToolbarModel()->input_in_progress() && | 806 bool is_visible = !GetToolbarModel()->input_in_progress() && |
808 browser_->search_model()->voice_search_supported(); | 807 browser_->search_model()->voice_search_supported(); |
809 if (mic_search_decoration_->IsVisible() == is_visible) | 808 if (mic_search_decoration_->IsVisible() == is_visible) |
810 return false; | 809 return false; |
811 mic_search_decoration_->SetVisible(is_visible); | 810 mic_search_decoration_->SetVisible(is_visible); |
812 return true; | 811 return true; |
813 } | 812 } |
OLD | NEW |