OLD | NEW |
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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/browser_main.h" | 5 #include "chrome/browser/browser_main.h" |
6 | 6 |
7 #include <algorithm> | 7 #include <algorithm> |
8 #include <string> | 8 #include <string> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 1159 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1170 bool first_run_ui_bypass = false; // True to skip first run UI. | 1170 bool first_run_ui_bypass = false; // True to skip first run UI. |
1171 if (is_first_run) { | 1171 if (is_first_run) { |
1172 first_run_ui_bypass = | 1172 first_run_ui_bypass = |
1173 !FirstRun::ProcessMasterPreferences(user_data_dir, &master_prefs); | 1173 !FirstRun::ProcessMasterPreferences(user_data_dir, &master_prefs); |
1174 AddFirstRunNewTabs(&browser_init, master_prefs.new_tabs); | 1174 AddFirstRunNewTabs(&browser_init, master_prefs.new_tabs); |
1175 | 1175 |
1176 // If we are running in App mode, we do not want to show the importer | 1176 // If we are running in App mode, we do not want to show the importer |
1177 // (first run) UI. | 1177 // (first run) UI. |
1178 if (!first_run_ui_bypass && | 1178 if (!first_run_ui_bypass && |
1179 (parsed_command_line.HasSwitch(switches::kApp) || | 1179 (parsed_command_line.HasSwitch(switches::kApp) || |
| 1180 parsed_command_line.HasSwitch(switches::kAppId) || |
1180 parsed_command_line.HasSwitch(switches::kNoFirstRun))) | 1181 parsed_command_line.HasSwitch(switches::kNoFirstRun))) |
1181 first_run_ui_bypass = true; | 1182 first_run_ui_bypass = true; |
1182 } | 1183 } |
1183 | 1184 |
1184 // TODO(viettrungluu): why don't we run this earlier? | 1185 // TODO(viettrungluu): why don't we run this earlier? |
1185 if (!parsed_command_line.HasSwitch(switches::kNoErrorDialogs)) | 1186 if (!parsed_command_line.HasSwitch(switches::kNoErrorDialogs)) |
1186 WarnAboutMinimumSystemRequirements(); | 1187 WarnAboutMinimumSystemRequirements(); |
1187 | 1188 |
1188 InitializeNetworkOptions(parsed_command_line); | 1189 InitializeNetworkOptions(parsed_command_line); |
1189 | 1190 |
(...skipping 505 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1695 #if defined(OS_CHROMEOS) | 1696 #if defined(OS_CHROMEOS) |
1696 // To be precise, logout (browser shutdown) is not yet done, but the | 1697 // To be precise, logout (browser shutdown) is not yet done, but the |
1697 // remaining work is negligible, hence we say LogoutDone here. | 1698 // remaining work is negligible, hence we say LogoutDone here. |
1698 chromeos::BootTimesLoader::Get()->AddLogoutTimeMarker("LogoutDone", | 1699 chromeos::BootTimesLoader::Get()->AddLogoutTimeMarker("LogoutDone", |
1699 false); | 1700 false); |
1700 chromeos::BootTimesLoader::Get()->WriteLogoutTimes(); | 1701 chromeos::BootTimesLoader::Get()->WriteLogoutTimes(); |
1701 #endif | 1702 #endif |
1702 TRACE_EVENT_END("BrowserMain", 0, 0); | 1703 TRACE_EVENT_END("BrowserMain", 0, 0); |
1703 return result_code; | 1704 return result_code; |
1704 } | 1705 } |
OLD | NEW |