| 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 #include <set> | 7 #include <set> |
| 8 #include <string> | 8 #include <string> |
| 9 #include <vector> | 9 #include <vector> |
| 10 | 10 |
| (...skipping 751 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 762 #if !defined(OS_ANDROID) | 762 #if !defined(OS_ANDROID) |
| 763 // On Android, first run is handled in Java code, and the C++ side of Chrome | 763 // On Android, first run is handled in Java code, and the C++ side of Chrome |
| 764 // doesn't know if this is the first run. This will cause some inaccuracy in | 764 // doesn't know if this is the first run. This will cause some inaccuracy in |
| 765 // the UMA statistics, but this should be minor (first runs are rare). | 765 // the UMA statistics, but this should be minor (first runs are rare). |
| 766 is_first_run = first_run::IsChromeFirstRun(); | 766 is_first_run = first_run::IsChromeFirstRun(); |
| 767 #endif // defined(OS_ANDROID) | 767 #endif // defined(OS_ANDROID) |
| 768 | 768 |
| 769 // Record collected startup metrics. | 769 // Record collected startup metrics. |
| 770 startup_metric_utils::RecordBrowserMainMessageLoopStart( | 770 startup_metric_utils::RecordBrowserMainMessageLoopStart( |
| 771 base::TimeTicks::Now(), is_first_run); | 771 base::TimeTicks::Now(), is_first_run); |
| 772 | |
| 773 startup_metric_utils::RecordTimeSinceLastStartup( | 772 startup_metric_utils::RecordTimeSinceLastStartup( |
| 774 g_browser_process->local_state()); | 773 g_browser_process->local_state()); |
| 774 startup_metric_utils::RecordStartupCount(g_browser_process->local_state()); |
| 775 } | 775 } |
| 776 | 776 |
| 777 // ----------------------------------------------------------------------------- | 777 // ----------------------------------------------------------------------------- |
| 778 // TODO(viettrungluu): move more/rest of BrowserMain() into BrowserMainParts. | 778 // TODO(viettrungluu): move more/rest of BrowserMain() into BrowserMainParts. |
| 779 | 779 |
| 780 #if defined(OS_WIN) | 780 #if defined(OS_WIN) |
| 781 #define DLLEXPORT __declspec(dllexport) | 781 #define DLLEXPORT __declspec(dllexport) |
| 782 | 782 |
| 783 // We use extern C for the prototype DLLEXPORT to avoid C++ name mangling. | 783 // We use extern C for the prototype DLLEXPORT to avoid C++ name mangling. |
| 784 extern "C" { | 784 extern "C" { |
| (...skipping 1078 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1863 chromeos::CrosSettings::Shutdown(); | 1863 chromeos::CrosSettings::Shutdown(); |
| 1864 #endif // defined(OS_CHROMEOS) | 1864 #endif // defined(OS_CHROMEOS) |
| 1865 #endif // defined(OS_ANDROID) | 1865 #endif // defined(OS_ANDROID) |
| 1866 } | 1866 } |
| 1867 | 1867 |
| 1868 // Public members: | 1868 // Public members: |
| 1869 | 1869 |
| 1870 void ChromeBrowserMainParts::AddParts(ChromeBrowserMainExtraParts* parts) { | 1870 void ChromeBrowserMainParts::AddParts(ChromeBrowserMainExtraParts* parts) { |
| 1871 chrome_extra_parts_.push_back(parts); | 1871 chrome_extra_parts_.push_back(parts); |
| 1872 } | 1872 } |
| OLD | NEW |