Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(43)

Side by Side Diff: content/app/content_main_runner.cc

Issue 317833006: [ICU] Avoid reading ICU data files in render process. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase Created 6 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
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 "content/public/app/content_main_runner.h" 5 #include "content/public/app/content_main_runner.h"
6 6
7 #include <stdlib.h> 7 #include <stdlib.h>
8 8
9 #include "base/allocator/allocator_extension.h" 9 #include "base/allocator/allocator_extension.h"
10 #include "base/at_exit.h" 10 #include "base/at_exit.h"
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
43 #include "content/renderer/in_process_renderer_thread.h" 43 #include "content/renderer/in_process_renderer_thread.h"
44 #include "content/utility/in_process_utility_thread.h" 44 #include "content/utility/in_process_utility_thread.h"
45 #include "crypto/nss_util.h" 45 #include "crypto/nss_util.h"
46 #include "ipc/ipc_descriptors.h" 46 #include "ipc/ipc_descriptors.h"
47 #include "ipc/ipc_switches.h" 47 #include "ipc/ipc_switches.h"
48 #include "media/base/media.h" 48 #include "media/base/media.h"
49 #include "sandbox/win/src/sandbox_types.h" 49 #include "sandbox/win/src/sandbox_types.h"
50 #include "ui/base/ui_base_paths.h" 50 #include "ui/base/ui_base_paths.h"
51 #include "ui/base/ui_base_switches.h" 51 #include "ui/base/ui_base_switches.h"
52 52
53 #if defined(OS_ANDROID)
54 #include "content/public/common/content_descriptors.h"
55 #endif
56
53 #if defined(USE_TCMALLOC) 57 #if defined(USE_TCMALLOC)
54 #include "third_party/tcmalloc/chromium/src/gperftools/malloc_extension.h" 58 #include "third_party/tcmalloc/chromium/src/gperftools/malloc_extension.h"
55 #if defined(TYPE_PROFILING) 59 #if defined(TYPE_PROFILING)
56 #include "base/allocator/type_profiler.h" 60 #include "base/allocator/type_profiler.h"
57 #include "base/allocator/type_profiler_tcmalloc.h" 61 #include "base/allocator/type_profiler_tcmalloc.h"
58 #endif 62 #endif
59 #endif 63 #endif
60 64
61 #if !defined(OS_IOS) 65 #if !defined(OS_IOS)
62 #include "content/app/mojo/mojo_init.h" 66 #include "content/app/mojo/mojo_init.h"
(...skipping 633 matching lines...) Expand 10 before | Expand all | Expand 10 after
696 #endif 700 #endif
697 701
698 #if defined(USE_NSS) 702 #if defined(USE_NSS)
699 crypto::EarlySetupForNSSInit(); 703 crypto::EarlySetupForNSSInit();
700 #endif 704 #endif
701 705
702 ui::RegisterPathProvider(); 706 ui::RegisterPathProvider();
703 RegisterPathProvider(); 707 RegisterPathProvider();
704 RegisterContentSchemes(true); 708 RegisterContentSchemes(true);
705 709
710 #if defined(OS_ANDROID)
711 int icudata_fd = base::GlobalDescriptors::GetInstance()->MaybeGet(
712 kAndroidICUDataDescriptor);
713 if (icudata_fd != -1)
714 CHECK(base::i18n::InitializeICUWithFileDescriptor(icudata_fd));
715 else
716 CHECK(base::i18n::InitializeICU());
717 #else
706 CHECK(base::i18n::InitializeICU()); 718 CHECK(base::i18n::InitializeICU());
719 #endif
707 720
708 InitializeStatsTable(command_line); 721 InitializeStatsTable(command_line);
709 722
710 if (delegate_) 723 if (delegate_)
711 delegate_->PreSandboxStartup(); 724 delegate_->PreSandboxStartup();
712 725
713 if (!process_type.empty()) 726 if (!process_type.empty())
714 CommonSubprocessInit(process_type); 727 CommonSubprocessInit(process_type);
715 728
716 #if defined(OS_WIN) 729 #if defined(OS_WIN)
(...skipping 99 matching lines...) Expand 10 before | Expand all | Expand 10 after
816 829
817 DISALLOW_COPY_AND_ASSIGN(ContentMainRunnerImpl); 830 DISALLOW_COPY_AND_ASSIGN(ContentMainRunnerImpl);
818 }; 831 };
819 832
820 // static 833 // static
821 ContentMainRunner* ContentMainRunner::Create() { 834 ContentMainRunner* ContentMainRunner::Create() {
822 return new ContentMainRunnerImpl(); 835 return new ContentMainRunnerImpl();
823 } 836 }
824 837
825 } // namespace content 838 } // namespace content
OLDNEW
« no previous file with comments | « chrome/browser/chrome_content_browser_client.cc ('k') | content/public/common/content_descriptors.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698