OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 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 #include "chrome/app/chrome_main_delegate.h" | 5 #include "chrome/app/chrome_main_delegate.h" |
6 | 6 |
7 #include "base/base_paths.h" | 7 #include "base/base_paths.h" |
8 #include "base/command_line.h" | 8 #include "base/command_line.h" |
9 #include "base/cpu.h" | 9 #include "base/cpu.h" |
10 #include "base/files/file_path.h" | 10 #include "base/files/file_path.h" |
(...skipping 724 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
735 base::GlobalDescriptors::GetInstance()->MaybeGet(extra_pak_keys[i]); | 735 base::GlobalDescriptors::GetInstance()->MaybeGet(extra_pak_keys[i]); |
736 CHECK(pak_fd != -1); | 736 CHECK(pak_fd != -1); |
737 ResourceBundle::GetSharedInstance().AddDataPackFromFile( | 737 ResourceBundle::GetSharedInstance().AddDataPackFromFile( |
738 base::File(pak_fd), ui::SCALE_FACTOR_100P); | 738 base::File(pak_fd), ui::SCALE_FACTOR_100P); |
739 } | 739 } |
740 | 740 |
741 base::i18n::SetICUDefaultLocale(locale); | 741 base::i18n::SetICUDefaultLocale(locale); |
742 const std::string loaded_locale = locale; | 742 const std::string loaded_locale = locale; |
743 #else | 743 #else |
744 const std::string loaded_locale = | 744 const std::string loaded_locale = |
745 ResourceBundle::InitSharedInstanceWithLocale(locale, NULL); | 745 ResourceBundle::InitSharedInstanceWithLocale(locale, NULL, true); |
746 | 746 |
747 base::FilePath resources_pack_path; | 747 base::FilePath resources_pack_path; |
748 PathService::Get(chrome::FILE_RESOURCES_PACK, &resources_pack_path); | 748 PathService::Get(chrome::FILE_RESOURCES_PACK, &resources_pack_path); |
749 ResourceBundle::GetSharedInstance().AddDataPackFromPath( | 749 ResourceBundle::GetSharedInstance().AddDataPackFromPath( |
750 resources_pack_path, ui::SCALE_FACTOR_NONE); | 750 resources_pack_path, ui::SCALE_FACTOR_NONE); |
751 #endif | 751 #endif |
752 CHECK(!loaded_locale.empty()) << "Locale could not be found for " << | 752 CHECK(!loaded_locale.empty()) << "Locale could not be found for " << |
753 locale; | 753 locale; |
754 | 754 |
755 #if !defined(CHROME_MULTIPLE_DLL_BROWSER) | 755 #if !defined(CHROME_MULTIPLE_DLL_BROWSER) |
(...skipping 169 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
925 } | 925 } |
926 | 926 |
927 content::ContentUtilityClient* | 927 content::ContentUtilityClient* |
928 ChromeMainDelegate::CreateContentUtilityClient() { | 928 ChromeMainDelegate::CreateContentUtilityClient() { |
929 #if defined(CHROME_MULTIPLE_DLL_BROWSER) | 929 #if defined(CHROME_MULTIPLE_DLL_BROWSER) |
930 return NULL; | 930 return NULL; |
931 #else | 931 #else |
932 return g_chrome_content_utility_client.Pointer(); | 932 return g_chrome_content_utility_client.Pointer(); |
933 #endif | 933 #endif |
934 } | 934 } |
OLD | NEW |