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/autocomplete/autocomplete_edit_view_mac.h" | 5 #include "chrome/browser/autocomplete/autocomplete_edit_view_mac.h" |
6 | 6 |
7 #include <Carbon/Carbon.h> // kVK_Return | 7 #include <Carbon/Carbon.h> // kVK_Return |
8 | 8 |
9 #include "app/mac/nsimage_cache.h" | 9 #include "app/mac/nsimage_cache.h" |
10 #include "app/resource_bundle.h" | 10 #include "app/resource_bundle.h" |
(...skipping 118 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
129 switch(resource_id) { | 129 switch(resource_id) { |
130 // From the autocomplete popup, or the star icon at the RHS of the | 130 // From the autocomplete popup, or the star icon at the RHS of the |
131 // text field. | 131 // text field. |
132 case IDR_STAR: image_name = @"star.pdf"; break; | 132 case IDR_STAR: image_name = @"star.pdf"; break; |
133 case IDR_STAR_LIT: image_name = @"star_lit.pdf"; break; | 133 case IDR_STAR_LIT: image_name = @"star_lit.pdf"; break; |
134 | 134 |
135 // Values from |AutocompleteMatch::TypeToIcon()|. | 135 // Values from |AutocompleteMatch::TypeToIcon()|. |
136 case IDR_OMNIBOX_SEARCH: image_name = @"omnibox_search.pdf"; break; | 136 case IDR_OMNIBOX_SEARCH: image_name = @"omnibox_search.pdf"; break; |
137 case IDR_OMNIBOX_HTTP: image_name = @"omnibox_http.pdf"; break; | 137 case IDR_OMNIBOX_HTTP: image_name = @"omnibox_http.pdf"; break; |
138 case IDR_OMNIBOX_HISTORY: image_name = @"omnibox_history.pdf"; break; | 138 case IDR_OMNIBOX_HISTORY: image_name = @"omnibox_history.pdf"; break; |
139 case IDR_OMNIBOX_MORE: image_name = @"omnibox_more.pdf"; break; | |
140 | 139 |
141 // Values from |ToolbarModel::GetIcon()|. | 140 // Values from |ToolbarModel::GetIcon()|. |
142 case IDR_OMNIBOX_HTTPS_VALID: | 141 case IDR_OMNIBOX_HTTPS_VALID: |
143 image_name = @"omnibox_https_valid.pdf"; break; | 142 image_name = @"omnibox_https_valid.pdf"; break; |
144 case IDR_OMNIBOX_HTTPS_WARNING: | 143 case IDR_OMNIBOX_HTTPS_WARNING: |
145 image_name = @"omnibox_https_warning.pdf"; break; | 144 image_name = @"omnibox_https_warning.pdf"; break; |
146 case IDR_OMNIBOX_HTTPS_INVALID: | 145 case IDR_OMNIBOX_HTTPS_INVALID: |
147 image_name = @"omnibox_https_invalid.pdf"; break; | 146 image_name = @"omnibox_https_invalid.pdf"; break; |
148 } | 147 } |
149 | 148 |
(...skipping 941 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1091 } | 1090 } |
1092 | 1091 |
1093 return std::wstring(); | 1092 return std::wstring(); |
1094 } | 1093 } |
1095 | 1094 |
1096 // static | 1095 // static |
1097 NSFont* AutocompleteEditViewMac::GetFieldFont() { | 1096 NSFont* AutocompleteEditViewMac::GetFieldFont() { |
1098 ResourceBundle& rb = ResourceBundle::GetSharedInstance(); | 1097 ResourceBundle& rb = ResourceBundle::GetSharedInstance(); |
1099 return rb.GetFont(ResourceBundle::BaseFont).GetNativeFont(); | 1098 return rb.GetFont(ResourceBundle::BaseFont).GetNativeFont(); |
1100 } | 1099 } |
OLD | NEW |