Chromium Code Reviews| 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/command_line.h" | 7 #include "base/command_line.h" |
| 8 #include "base/files/file_path.h" | 8 #include "base/files/file_path.h" |
| 9 #include "base/lazy_instance.h" | 9 #include "base/lazy_instance.h" |
| 10 #include "base/message_loop/message_loop.h" | 10 #include "base/message_loop/message_loop.h" |
| (...skipping 322 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 333 #endif // OS_POSIX | 333 #endif // OS_POSIX |
| 334 | 334 |
| 335 struct MainFunction { | 335 struct MainFunction { |
| 336 const char* name; | 336 const char* name; |
| 337 int (*function)(const content::MainFunctionParams&); | 337 int (*function)(const content::MainFunctionParams&); |
| 338 }; | 338 }; |
| 339 | 339 |
| 340 } // namespace | 340 } // namespace |
| 341 | 341 |
| 342 ChromeMainDelegate::ChromeMainDelegate() { | 342 ChromeMainDelegate::ChromeMainDelegate() { |
| 343 #if !defined(OS_ANDROID) | |
| 343 startup_metric_utils::RecordMainEntryPointTime(); | 344 startup_metric_utils::RecordMainEntryPointTime(); |
| 345 #else | |
| 346 // On Android the main entry point time is when the Java code starts, not here. | |
|
jeremy
2013/08/28 18:15:56
nit: not here -> this happens before the C++ side
aberent
2013/08/29 11:45:13
Done.
| |
| 347 // The Java side has recorded that, but the C++ side can't fetch it from the | |
| 348 // Java side until we have initialized the JNI. See ChromeMainDelegateAndroid. | |
| 349 #endif | |
| 344 } | 350 } |
| 345 | 351 |
| 346 ChromeMainDelegate::~ChromeMainDelegate() { | 352 ChromeMainDelegate::~ChromeMainDelegate() { |
| 347 } | 353 } |
| 348 | 354 |
| 349 bool ChromeMainDelegate::BasicStartupComplete(int* exit_code) { | 355 bool ChromeMainDelegate::BasicStartupComplete(int* exit_code) { |
| 350 #if defined(OS_CHROMEOS) | 356 #if defined(OS_CHROMEOS) |
| 351 chromeos::BootTimesLoader::Get()->SaveChromeMainStats(); | 357 chromeos::BootTimesLoader::Get()->SaveChromeMainStats(); |
| 352 #endif | 358 #endif |
| 353 | 359 |
| (...skipping 503 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 857 } | 863 } |
| 858 | 864 |
| 859 content::ContentUtilityClient* | 865 content::ContentUtilityClient* |
| 860 ChromeMainDelegate::CreateContentUtilityClient() { | 866 ChromeMainDelegate::CreateContentUtilityClient() { |
| 861 #if defined(CHROME_MULTIPLE_DLL_BROWSER) | 867 #if defined(CHROME_MULTIPLE_DLL_BROWSER) |
| 862 return NULL; | 868 return NULL; |
| 863 #else | 869 #else |
| 864 return &g_chrome_content_utility_client.Get(); | 870 return &g_chrome_content_utility_client.Get(); |
| 865 #endif | 871 #endif |
| 866 } | 872 } |
| OLD | NEW |