| 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 "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 653 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 664 base::RouteStdioToConsole(); | 664 base::RouteStdioToConsole(); |
| 665 #endif | 665 #endif |
| 666 | 666 |
| 667 // Enable startup tracing asap to avoid early TRACE_EVENT calls being | 667 // Enable startup tracing asap to avoid early TRACE_EVENT calls being |
| 668 // ignored. | 668 // ignored. |
| 669 if (command_line.HasSwitch(switches::kTraceStartup)) { | 669 if (command_line.HasSwitch(switches::kTraceStartup)) { |
| 670 base::debug::CategoryFilter category_filter( | 670 base::debug::CategoryFilter category_filter( |
| 671 command_line.GetSwitchValueASCII(switches::kTraceStartup)); | 671 command_line.GetSwitchValueASCII(switches::kTraceStartup)); |
| 672 base::debug::TraceLog::GetInstance()->SetEnabled( | 672 base::debug::TraceLog::GetInstance()->SetEnabled( |
| 673 category_filter, | 673 category_filter, |
| 674 base::debug::TraceLog::RECORDING_MODE, | |
| 675 base::debug::TraceLog::RECORD_UNTIL_FULL); | 674 base::debug::TraceLog::RECORD_UNTIL_FULL); |
| 676 } | 675 } |
| 677 #if !defined(OS_ANDROID) | 676 #if !defined(OS_ANDROID) |
| 678 // Android tracing started at the beginning of the method. | 677 // Android tracing started at the beginning of the method. |
| 679 // Other OSes have to wait till we get here in order for all the memory | 678 // Other OSes have to wait till we get here in order for all the memory |
| 680 // management setup to be completed. | 679 // management setup to be completed. |
| 681 TRACE_EVENT0("startup", "ContentMainRunnerImpl::Initialize"); | 680 TRACE_EVENT0("startup", "ContentMainRunnerImpl::Initialize"); |
| 682 #endif // !OS_ANDROID | 681 #endif // !OS_ANDROID |
| 683 | 682 |
| 684 #if defined(OS_MACOSX) && !defined(OS_IOS) | 683 #if defined(OS_MACOSX) && !defined(OS_IOS) |
| (...skipping 165 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 850 | 849 |
| 851 DISALLOW_COPY_AND_ASSIGN(ContentMainRunnerImpl); | 850 DISALLOW_COPY_AND_ASSIGN(ContentMainRunnerImpl); |
| 852 }; | 851 }; |
| 853 | 852 |
| 854 // static | 853 // static |
| 855 ContentMainRunner* ContentMainRunner::Create() { | 854 ContentMainRunner* ContentMainRunner::Create() { |
| 856 return new ContentMainRunnerImpl(); | 855 return new ContentMainRunnerImpl(); |
| 857 } | 856 } |
| 858 | 857 |
| 859 } // namespace content | 858 } // namespace content |
| OLD | NEW |