diff options
Diffstat (limited to 'chrome/browser')
-rw-r--r-- | chrome/browser/language_combobox_model.cc (renamed from chrome/browser/views/options/language_combobox_model.cc) | 13 | ||||
-rw-r--r-- | chrome/browser/language_combobox_model.h (renamed from chrome/browser/views/options/language_combobox_model.h) | 12 | ||||
-rw-r--r-- | chrome/browser/views/options/advanced_contents_view.cc | 1 | ||||
-rw-r--r-- | chrome/browser/views/options/languages_page_view.cc | 2 |
4 files changed, 16 insertions, 12 deletions
diff --git a/chrome/browser/views/options/language_combobox_model.cc b/chrome/browser/language_combobox_model.cc index a026ab6..97efadd 100644 --- a/chrome/browser/views/options/language_combobox_model.cc +++ b/chrome/browser/language_combobox_model.cc @@ -1,8 +1,8 @@ -// Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. +// Copyright (c) 2009 The Chromium Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -#include "chrome/browser/views/options/language_combobox_model.h" +#include "chrome/browser/language_combobox_model.h" #include "app/l10n_util.h" #include "base/string_util.h" @@ -50,20 +50,21 @@ void LanguageComboboxModel::InitNativeNames( UErrorCode error = U_ZERO_ERROR; const int buffer_size = 1024; - std::wstring name_local; + string16 name_local; int actual_size = uloc_getDisplayName(locale_code, app_locale.c_str(), WriteInto(&name_local, buffer_size + 1), buffer_size, &error); DCHECK(U_SUCCESS(error)); name_local.resize(actual_size); - std::wstring name_native; + string16 name_native; actual_size = uloc_getDisplayName(locale_code, locale_code, WriteInto(&name_native, buffer_size + 1), buffer_size, &error); DCHECK(U_SUCCESS(error)); name_native.resize(actual_size); - locale_names_.push_back(name_local); - native_names_[name_local] = LocaleData(name_native, locale_codes[i]); + locale_names_.push_back(UTF16ToWideHack(name_local)); + native_names_[UTF16ToWideHack(name_local)] = LocaleData( + UTF16ToWideHack(name_native), locale_codes[i]); } // Sort using locale specific sorter. diff --git a/chrome/browser/views/options/language_combobox_model.h b/chrome/browser/language_combobox_model.h index 6298925..297d32a 100644 --- a/chrome/browser/views/options/language_combobox_model.h +++ b/chrome/browser/language_combobox_model.h @@ -1,9 +1,13 @@ -// Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. +// Copyright (c) 2009 The Chromium Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -#ifndef CHROME_BROWSER_VIEWS_OPTIONS_LANGUAGE_COMBOBOX_MODEL_H_ -#define CHROME_BROWSER_VIEWS_OPTIONS_LANGUAGE_COMBOBOX_MODEL_H_ +#ifndef CHROME_BROWSER_LANGUAGE_COMBOBOX_MODEL_H_ +#define CHROME_BROWSER_LANGUAGE_COMBOBOX_MODEL_H_ + +#include <map> +#include <string> +#include <vector> #include "app/combobox_model.h" #include "chrome/browser/profile.h" @@ -67,4 +71,4 @@ class LanguageComboboxModel : public ComboboxModel { DISALLOW_COPY_AND_ASSIGN(LanguageComboboxModel); }; -#endif // #ifndef CHROME_BROWSER_VIEWS_OPTIONS_LANGUAGE_COMBOBOX_MODEL_H_ +#endif // #ifndef CHROME_BROWSER_LANGUAGE_COMBOBOX_MODEL_H_ diff --git a/chrome/browser/views/options/advanced_contents_view.cc b/chrome/browser/views/options/advanced_contents_view.cc index d72ef65..134b5c1 100644 --- a/chrome/browser/views/options/advanced_contents_view.cc +++ b/chrome/browser/views/options/advanced_contents_view.cc @@ -31,7 +31,6 @@ #include "chrome/browser/shell_dialogs.h" #include "chrome/browser/views/options/cookies_view.h" #include "chrome/browser/views/options/fonts_languages_window_view.h" -#include "chrome/browser/views/options/language_combobox_model.h" #include "chrome/browser/views/restart_message_box.h" #include "chrome/common/pref_member.h" #include "chrome/common/pref_names.h" diff --git a/chrome/browser/views/options/languages_page_view.cc b/chrome/browser/views/options/languages_page_view.cc index 9ff8da0e..abb2490 100644 --- a/chrome/browser/views/options/languages_page_view.cc +++ b/chrome/browser/views/options/languages_page_view.cc @@ -18,10 +18,10 @@ #include "base/gfx/native_theme.h" #include "base/string_util.h" #include "chrome/browser/browser_process.h" +#include "chrome/browser/language_combobox_model.h" #include "chrome/browser/language_order_table_model.h" #include "chrome/browser/shell_dialogs.h" #include "chrome/browser/spellchecker.h" -#include "chrome/browser/views/options/language_combobox_model.h" #include "chrome/browser/views/restart_message_box.h" #include "chrome/common/chrome_switches.h" #include "chrome/common/pref_names.h" |