| 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 #ifndef CHROME_BROWSER_CHROME_BROWSER_MAIN_H_ | 5 #ifndef CHROME_BROWSER_CHROME_BROWSER_MAIN_H_ |
| 6 #define CHROME_BROWSER_CHROME_BROWSER_MAIN_H_ | 6 #define CHROME_BROWSER_CHROME_BROWSER_MAIN_H_ |
| 7 | 7 |
| 8 #include "base/basictypes.h" | 8 #include "base/basictypes.h" |
| 9 #include "base/memory/scoped_ptr.h" | 9 #include "base/memory/scoped_ptr.h" |
| 10 #include "base/metrics/field_trial.h" | 10 #include "base/metrics/field_trial.h" |
| (...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 80 virtual void PostProfileInit(); | 80 virtual void PostProfileInit(); |
| 81 virtual void PreBrowserStart(); | 81 virtual void PreBrowserStart(); |
| 82 virtual void PostBrowserStart(); | 82 virtual void PostBrowserStart(); |
| 83 | 83 |
| 84 // Displays a warning message that we can't find any locale data files. | 84 // Displays a warning message that we can't find any locale data files. |
| 85 virtual void ShowMissingLocaleMessageBox() = 0; | 85 virtual void ShowMissingLocaleMessageBox() = 0; |
| 86 | 86 |
| 87 const content::MainFunctionParams& parameters() const { | 87 const content::MainFunctionParams& parameters() const { |
| 88 return parameters_; | 88 return parameters_; |
| 89 } | 89 } |
| 90 const CommandLine& parsed_command_line() const { | 90 const base::CommandLine& parsed_command_line() const { |
| 91 return parsed_command_line_; | 91 return parsed_command_line_; |
| 92 } | 92 } |
| 93 | 93 |
| 94 Profile* profile() { return profile_; } | 94 Profile* profile() { return profile_; } |
| 95 | 95 |
| 96 const PrefService* local_state() const { return local_state_; } | 96 const PrefService* local_state() const { return local_state_; } |
| 97 | 97 |
| 98 private: | 98 private: |
| 99 // Methods for |SetupMetricsAndFieldTrials()| -------------------------------- | 99 // Methods for |SetupMetricsAndFieldTrials()| -------------------------------- |
| 100 | 100 |
| (...skipping 18 matching lines...) Expand all Loading... |
| 119 void RecordPreReadExperimentTime(const char* name, base::TimeDelta time); | 119 void RecordPreReadExperimentTime(const char* name, base::TimeDelta time); |
| 120 | 120 |
| 121 // Methods for Main Message Loop ------------------------------------------- | 121 // Methods for Main Message Loop ------------------------------------------- |
| 122 | 122 |
| 123 int PreCreateThreadsImpl(); | 123 int PreCreateThreadsImpl(); |
| 124 int PreMainMessageLoopRunImpl(); | 124 int PreMainMessageLoopRunImpl(); |
| 125 | 125 |
| 126 // Members initialized on construction --------------------------------------- | 126 // Members initialized on construction --------------------------------------- |
| 127 | 127 |
| 128 const content::MainFunctionParams parameters_; | 128 const content::MainFunctionParams parameters_; |
| 129 const CommandLine& parsed_command_line_; | 129 const base::CommandLine& parsed_command_line_; |
| 130 int result_code_; | 130 int result_code_; |
| 131 | 131 |
| 132 // Create StartupTimeBomb object for watching jank during startup. | 132 // Create StartupTimeBomb object for watching jank during startup. |
| 133 scoped_ptr<StartupTimeBomb> startup_watcher_; | 133 scoped_ptr<StartupTimeBomb> startup_watcher_; |
| 134 | 134 |
| 135 // Create ShutdownWatcherHelper object for watching jank during shutdown. | 135 // Create ShutdownWatcherHelper object for watching jank during shutdown. |
| 136 // Please keep |shutdown_watcher| as the first object constructed, and hence | 136 // Please keep |shutdown_watcher| as the first object constructed, and hence |
| 137 // it is destroyed last. | 137 // it is destroyed last. |
| 138 scoped_ptr<ShutdownWatcherHelper> shutdown_watcher_; | 138 scoped_ptr<ShutdownWatcherHelper> shutdown_watcher_; |
| 139 | 139 |
| (...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 190 bool restart_last_session_; | 190 bool restart_last_session_; |
| 191 | 191 |
| 192 // Tests can set this to true to disable restricting cookie access in the | 192 // Tests can set this to true to disable restricting cookie access in the |
| 193 // network stack, as this can only be done once. | 193 // network stack, as this can only be done once. |
| 194 static bool disable_enforcing_cookie_policies_for_tests_; | 194 static bool disable_enforcing_cookie_policies_for_tests_; |
| 195 | 195 |
| 196 DISALLOW_COPY_AND_ASSIGN(ChromeBrowserMainParts); | 196 DISALLOW_COPY_AND_ASSIGN(ChromeBrowserMainParts); |
| 197 }; | 197 }; |
| 198 | 198 |
| 199 #endif // CHROME_BROWSER_CHROME_BROWSER_MAIN_H_ | 199 #endif // CHROME_BROWSER_CHROME_BROWSER_MAIN_H_ |
| OLD | NEW |