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/custom_home_pages_table_model.h" | 5 #include "chrome/browser/custom_home_pages_table_model.h" |
6 | 6 |
7 #include "app/l10n_util.h" | 7 #include "app/l10n_util.h" |
8 #include "app/resource_bundle.h" | 8 #include "app/resource_bundle.h" |
9 #include "app/table_model_observer.h" | 9 #include "app/table_model_observer.h" |
10 #include "base/i18n/rtl.h" | 10 #include "base/i18n/rtl.h" |
(...skipping 191 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
202 *index = static_cast<int>(i); | 202 *index = static_cast<int>(i); |
203 return &entries_[i]; | 203 return &entries_[i]; |
204 } | 204 } |
205 } | 205 } |
206 return NULL; | 206 return NULL; |
207 } | 207 } |
208 | 208 |
209 std::wstring CustomHomePagesTableModel::FormattedURL(int row) const { | 209 std::wstring CustomHomePagesTableModel::FormattedURL(int row) const { |
210 std::wstring languages = | 210 std::wstring languages = |
211 UTF8ToWide(profile_->GetPrefs()->GetString(prefs::kAcceptLanguages)); | 211 UTF8ToWide(profile_->GetPrefs()->GetString(prefs::kAcceptLanguages)); |
212 std::wstring url(net::FormatUrl(entries_[row].url, languages)); | 212 string16 url = WideToUTF16(net::FormatUrl(entries_[row].url, languages)); |
213 base::i18n::GetDisplayStringInLTRDirectionality(&url); | 213 url = base::i18n::GetDisplayStringInLTRDirectionality(url); |
214 return url; | 214 return UTF16ToWide(url); |
215 } | 215 } |
OLD | NEW |