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_android.h" | 5 #include "chrome/browser/chrome_browser_main_android.h" |
6 | 6 |
7 #include "base/base_switches.h" | 7 #include "base/base_switches.h" |
8 #include "base/command_line.h" | 8 #include "base/command_line.h" |
9 #include "base/files/file_path.h" | 9 #include "base/files/file_path.h" |
10 #include "base/files/file_util.h" | 10 #include "base/files/file_util.h" |
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
63 if (!breakpad_enabled) | 63 if (!breakpad_enabled) |
64 breakpad_enabled = base::CommandLine::ForCurrentProcess()->HasSwitch( | 64 breakpad_enabled = base::CommandLine::ForCurrentProcess()->HasSwitch( |
65 switches::kEnableCrashReporterForTesting); | 65 switches::kEnableCrashReporterForTesting); |
66 | 66 |
67 if (breakpad_enabled) { | 67 if (breakpad_enabled) { |
68 base::FilePath crash_dump_dir; | 68 base::FilePath crash_dump_dir; |
69 PathService::Get(chrome::DIR_CRASH_DUMPS, &crash_dump_dir); | 69 PathService::Get(chrome::DIR_CRASH_DUMPS, &crash_dump_dir); |
70 crash_dump_manager_.reset(new breakpad::CrashDumpManager(crash_dump_dir)); | 70 crash_dump_manager_.reset(new breakpad::CrashDumpManager(crash_dump_dir)); |
71 } | 71 } |
72 | 72 |
73 ui::SetLocalePaksStoredInApk(false); | 73 // Auto-detect based on en-US whether locale .pak files are store uncompressed |
| 74 // (monochrome) vs extracted (non-monochrome). |
| 75 ui::SetLocalePaksStoredInApk( |
| 76 !ui::GetPathForAndroidLocalePakWithinApk("en-US").empty()); |
74 | 77 |
75 return ChromeBrowserMainParts::PreCreateThreads(); | 78 return ChromeBrowserMainParts::PreCreateThreads(); |
76 } | 79 } |
77 | 80 |
78 void ChromeBrowserMainPartsAndroid::PostProfileInit() { | 81 void ChromeBrowserMainPartsAndroid::PostProfileInit() { |
79 ChromeBrowserMainParts::PostProfileInit(); | 82 ChromeBrowserMainParts::PostProfileInit(); |
80 | 83 |
81 // Previously we stored information related to salient images for bookmarks | 84 // Previously we stored information related to salient images for bookmarks |
82 // in a local file. We replaced the salient images with favicons. As part | 85 // in a local file. We replaced the salient images with favicons. As part |
83 // of the clean up, the local file needs to be deleted. See crbug.com/499415. | 86 // of the clean up, the local file needs to be deleted. See crbug.com/499415. |
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
124 content::BrowserThread::GetBlockingPool()->PostDelayedTask(FROM_HERE, | 127 content::BrowserThread::GetBlockingPool()->PostDelayedTask(FROM_HERE, |
125 base::Bind(&SeccompSupportDetector::StartDetection), | 128 base::Bind(&SeccompSupportDetector::StartDetection), |
126 base::TimeDelta::FromMinutes(1)); | 129 base::TimeDelta::FromMinutes(1)); |
127 | 130 |
128 RegisterChromeJavaMojoInterfaces(); | 131 RegisterChromeJavaMojoInterfaces(); |
129 } | 132 } |
130 | 133 |
131 void ChromeBrowserMainPartsAndroid::ShowMissingLocaleMessageBox() { | 134 void ChromeBrowserMainPartsAndroid::ShowMissingLocaleMessageBox() { |
132 NOTREACHED(); | 135 NOTREACHED(); |
133 } | 136 } |
OLD | NEW |