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/browser/chrome_browser_main.h" | 5 #include "chrome/browser/chrome_browser_main.h" |
6 | 6 |
7 #if defined(TOOLKIT_GTK) | 7 #if defined(TOOLKIT_GTK) |
8 #include <gtk/gtk.h> | 8 #include <gtk/gtk.h> |
9 #endif | 9 #endif |
10 | 10 |
(...skipping 874 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
885 } else { | 885 } else { |
886 // Mac starts it earlier in |PreMainMessageLoopStart()| (because it is | 886 // Mac starts it earlier in |PreMainMessageLoopStart()| (because it is |
887 // needed when loading the MainMenu.nib and the language doesn't depend on | 887 // needed when loading the MainMenu.nib and the language doesn't depend on |
888 // anything since it comes from Cocoa. | 888 // anything since it comes from Cocoa. |
889 #if defined(OS_MACOSX) | 889 #if defined(OS_MACOSX) |
890 browser_process_->SetApplicationLocale(l10n_util::GetLocaleOverride()); | 890 browser_process_->SetApplicationLocale(l10n_util::GetLocaleOverride()); |
891 #else | 891 #else |
892 const std::string locale = | 892 const std::string locale = |
893 local_state_->GetString(prefs::kApplicationLocale); | 893 local_state_->GetString(prefs::kApplicationLocale); |
894 | 894 |
895 #if defined(OS_WIN) | |
896 gfx::EnableHighDPISupport(); | |
897 #endif | |
898 | |
899 // On a POSIX OS other than ChromeOS, the parameter that is passed to the | 895 // On a POSIX OS other than ChromeOS, the parameter that is passed to the |
900 // method InitSharedInstance is ignored. | 896 // method InitSharedInstance is ignored. |
901 | 897 |
902 TRACE_EVENT_BEGIN0("startup", | 898 TRACE_EVENT_BEGIN0("startup", |
903 "ChromeBrowserMainParts::PreCreateThreadsImpl:InitResourceBundle"); | 899 "ChromeBrowserMainParts::PreCreateThreadsImpl:InitResourceBundle"); |
904 const std::string loaded_locale = | 900 const std::string loaded_locale = |
905 ResourceBundle::InitSharedInstanceWithLocale(locale, NULL); | 901 ResourceBundle::InitSharedInstanceWithLocale(locale, NULL); |
906 TRACE_EVENT_END0("startup", | 902 TRACE_EVENT_END0("startup", |
907 "ChromeBrowserMainParts::PreCreateThreadsImpl:InitResourceBundle"); | 903 "ChromeBrowserMainParts::PreCreateThreadsImpl:InitResourceBundle"); |
908 | 904 |
(...skipping 790 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1699 chromeos::CrosSettings::Shutdown(); | 1695 chromeos::CrosSettings::Shutdown(); |
1700 #endif | 1696 #endif |
1701 #endif | 1697 #endif |
1702 } | 1698 } |
1703 | 1699 |
1704 // Public members: | 1700 // Public members: |
1705 | 1701 |
1706 void ChromeBrowserMainParts::AddParts(ChromeBrowserMainExtraParts* parts) { | 1702 void ChromeBrowserMainParts::AddParts(ChromeBrowserMainExtraParts* parts) { |
1707 chrome_extra_parts_.push_back(parts); | 1703 chrome_extra_parts_.push_back(parts); |
1708 } | 1704 } |
OLD | NEW |